From e84fb0d6d9aca4f8a49ae4d551d139b71b68d935 Mon Sep 17 00:00:00 2001 From: Beppe Date: Mon, 9 Sep 2024 17:05:50 +0200 Subject: [PATCH] Impostazione visualizzazione mappa satellite --- modules/interventi/plugins/mappa.php | 2 +- modules/mappa/edit.php | 2 +- update/2_5_5.sql | 10 +++++++++- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/modules/interventi/plugins/mappa.php b/modules/interventi/plugins/mappa.php index 1078fb638..ac6b13a47 100644 --- a/modules/interventi/plugins/mappa.php +++ b/modules/interventi/plugins/mappa.php @@ -122,7 +122,7 @@ if (get('op') == 'getmappa') { const lt = "41.706"; const ln = "13.228"; var container = L.DomUtil.get("mappa"); - var esri_url ="https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}"; + var esri_url = ''; var esri_attribution = "© Esri © OpenStreetMap Contributors"; if(container._leaflet_id != null){ diff --git a/modules/mappa/edit.php b/modules/mappa/edit.php index abf13f505..4ee8f2433 100644 --- a/modules/mappa/edit.php +++ b/modules/mappa/edit.php @@ -94,7 +94,7 @@ foreach ($rs_stati as $stato) { var coords = []; var circle = ""; var ROOTDIR = ''; - var esri_url ="https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}"; + var esri_url = ''; var esri_attribution = "© Esri © OpenStreetMap Contributors"; function caricaMappa() { diff --git a/update/2_5_5.sql b/update/2_5_5.sql index e5aafb5d8..764173d8b 100644 --- a/update/2_5_5.sql +++ b/update/2_5_5.sql @@ -29,4 +29,12 @@ UPDATE `zz_widgets` SET `class` = 'col-md-6' WHERE `zz_widgets`.`name` = "Spazio -- Gestione tipi destinatari e autocompletamenti destinatari nelle mail in uscita ALTER TABLE `em_templates` ADD `type` varchar(5) NOT NULL DEFAULT 'a' AFTER `note_aggiuntive`, - ADD `indirizzi_proposti` TINYINT NOT NULL DEFAULT '0' AFTER `type`; \ No newline at end of file + ADD `indirizzi_proposti` TINYINT NOT NULL DEFAULT '0' AFTER `type`; + +-- Aggiunta visualizzazione satellite in mappa +INSERT INTO `zz_settings` (`id`, `nome`, `valore`, `tipo`, `editable`, `sezione`) VALUES +(NULL, 'Tile server satellite', 'https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}', 'string', '1', 'Generali'); + +INSERT INTO `zz_settings_lang` (`id`, `id_lang`, `id_record`, `title`, `help`) VALUES +(NULL, '1', (SELECT `zz_settings`.`id` FROM `zz_settings` WHERE `zz_settings`.`nome` = 'Tile server satellite'), 'Tile server satellite', ''), +(NULL, '2', (SELECT `zz_settings`.`id` FROM `zz_settings` WHERE `zz_settings`.`nome` = 'Tile server satellite'), 'Satellite tile server', ''); \ No newline at end of file