您可以参考这个代码
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title data-i18n="resources.title_tiledMapLayer4326"></title>
<script type="text/javascript" src="../js/include-web.js"></script>
</head>
<body style=" margin: 0;overflow: hidden;background: #fff;width: 100%;height:100%;position: absolute;top: 0;">
<div id="map" style="margin:0 auto;width: 100%;height: 100%"></div>
<script type="text/javascript" src="../../dist/leaflet/include-leaflet.js"></script>
<script type="text/javascript">
var host = window.isLocal ? window.server : "https://iserver.supermap.io";
var map, url = host + "/iserver/services/map-world/rest/maps/World";
map = L.map('map', {
crs: L.CRS.EPSG4326,
center: [0, 0],
maxZoom: 18,
zoom: 1
});
var latlng = [];
var marker;
L.supermap.tiledMapLayer(url).addTo(map);
map.on('click',function(e){
latlng.push([e.latlng.lat,e.latlng.lng]);
if(latlng.length>1){
marker.remove();
marker = L.marker(latlng[latlng.length-1]).addTo(map);
}
else{
marker = L.marker(latlng[0]).addTo(map);
}
});
</script>
</body>
</html>