From 92d3b21272cce7f35bece0c4b38828d7cd1b3d25 Mon Sep 17 00:00:00 2001 From: Emilie Genton Date: Wed, 17 Jan 2024 12:16:26 +0100 Subject: [PATCH] Prend en compte si le lien IGN est "non libre"... MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ... Ajout d'une propriété "private" qui est true ou false dans le carte.json + etude.json pour la couverture hydraulique Issue: #203376 Change-Id: Ic920ca18ec7b48c134413aab877a1d799440c0e8 --- client-ng/src/components/OlMap.vue | 5 +++-- remocra/src/main/webapp/js/app/remocra/widget/map/Map.js | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/client-ng/src/components/OlMap.vue b/client-ng/src/components/OlMap.vue index 3c56475e9..8e7a013d3 100644 --- a/client-ng/src/components/OlMap.vue +++ b/client-ng/src/components/OlMap.vue @@ -300,6 +300,7 @@ import Indicateur from './Indicateur.vue' import { getSrid } from './utils/FunctionsUtils.js'; const IGN_URL = 'https://data.geopf.fr/wmts' +const IGN_URL_PRIVATE = 'https://data.geopf.fr/private/wmts?apikey=ign_scan_ws' export default { name: 'OlMap', @@ -813,7 +814,7 @@ export default { return wmsLayer }, createIGNLayer(layerDef) { - layerDef.url = IGN_URL; + layerDef.url = layerDef.isPrivate == true ? IGN_URL_PRIVATE : IGN_URL; layerDef.projection = 'EPSG:3857' layerDef.matrixSet = 'PM' layerDef.attribution = '' + '' + '