No point layers in control; add visibility toggle in menu

This commit is contained in:
2025-02-10 15:07:13 +01:00
parent be6398b1aa
commit 64af485a54
5 changed files with 97 additions and 28 deletions

View File

@@ -138,11 +138,6 @@ GIS.initMap = async function (mapId, zoomLevel = this.INIT_ZOOM) {
let prehistoric = await this.prehistoric();
const archeo = {
'Beni archeologici (punti)' : markersGroup,
'Beni archeologici (strutture)' : sitesGroup,
'Beni non conservati' : notConservedGroup,
'Rinvenimenti' : findingsGroup,
'Siti preistorici' : prehistoric,
'Vincoli archeologici' : layerVincoli,
'Vincoli paesistici' : layerPaesistici,
};
@@ -155,6 +150,11 @@ GIS.initMap = async function (mapId, zoomLevel = this.INIT_ZOOM) {
findingsGroup.addTo(map);
prehistoric.addTo(map);
window.Sites = markersGroup;
window.NotConserved = notConservedGroup;
window.Findings = findingsGroup;
window.Prehistoric = prehistoric;
L.control.layers(baseMap, archeo).addTo(map);
return map;