Move boundaries to base map control
This commit is contained in:
parent
377447f63a
commit
e3d98c2e5d
@ -70,7 +70,6 @@ GIS.initMap = async function (mapId, zoomLevel = this.INIT_ZOOM) {
|
|||||||
|
|
||||||
let layerVincoli = await this.loadGeoJSON('vincoli.geojson', Options.constraintsArch);
|
let layerVincoli = await this.loadGeoJSON('vincoli.geojson', Options.constraintsArch);
|
||||||
let layerPaesistici = await this.loadGeoJSON('paesistici.geojson', Options.constraintsLand);
|
let layerPaesistici = await this.loadGeoJSON('paesistici.geojson', Options.constraintsLand);
|
||||||
let boundaries = await this.loadGeoJSON('confini.geojson', {}, false);
|
|
||||||
let buildings = await this.loadGeoJSON('fabbricati.geojson', Options.buildings, false);
|
let buildings = await this.loadGeoJSON('fabbricati.geojson', Options.buildings, false);
|
||||||
|
|
||||||
await this.addLayerGroups(map);
|
await this.addLayerGroups(map);
|
||||||
@ -92,7 +91,6 @@ GIS.initMap = async function (mapId, zoomLevel = this.INIT_ZOOM) {
|
|||||||
);
|
);
|
||||||
const cartography = {
|
const cartography = {
|
||||||
'Catasto Agenzia delle Entrate (zoom per visualizzare)' : wmsLayer,
|
'Catasto Agenzia delle Entrate (zoom per visualizzare)' : wmsLayer,
|
||||||
'Limiti comuni' : boundaries,
|
|
||||||
'Fabbricati' : buildings,
|
'Fabbricati' : buildings,
|
||||||
'Vincoli archeologici' : layerVincoli,
|
'Vincoli archeologici' : layerVincoli,
|
||||||
'Vincoli paesaggistici' : layerPaesistici,
|
'Vincoli paesaggistici' : layerPaesistici,
|
||||||
@ -355,11 +353,14 @@ GIS.initLayers = async function(map) {
|
|||||||
attribution: '© Mapbox'
|
attribution: '© Mapbox'
|
||||||
});
|
});
|
||||||
|
|
||||||
|
let boundaries = await this.loadGeoJSON('confini.geojson', {}, false);
|
||||||
|
|
||||||
const baseGroup = new L.LayerGroup([osmap]);
|
const baseGroup = new L.LayerGroup([osmap]);
|
||||||
baseGroup.addTo(map);
|
baseGroup.addTo(map);
|
||||||
const baseMap = {
|
const baseMap = {
|
||||||
"OpenStreetMap" : osmap,
|
"OpenStreetMap" : osmap,
|
||||||
"Satellite" : mapbox,
|
"Satellite" : mapbox,
|
||||||
|
'Limiti amministrativi' : boundaries,
|
||||||
};
|
};
|
||||||
|
|
||||||
return baseMap;
|
return baseMap;
|
||||||
|
Loading…
Reference in New Issue
Block a user