Skip to content
Snippets Groups Projects
Commit d776c2f4 authored by Lene Wasskog's avatar Lene Wasskog
Browse files

Merge branch 'updateWMSSource-VIPSUTV-719' into 'development'

Update WMS source for background map (Norway)

See merge request !4
parents e7005964 6fe6da74
No related branches found
No related tags found
1 merge request!4Update WMS source for background map (Norway)
...@@ -68,7 +68,7 @@ ...@@ -68,7 +68,7 @@
CONST_URL_STATIC_IMAGE_PATH: '/static/images/observations/', CONST_URL_STATIC_IMAGE_PATH: '/static/images/observations/',
CONST_GPS_URL_NORWAY_MAP: 'https://opencache.statkart.no/gatekeeper/gk/gk.open_wmts?Version=1.0.0&service=wmts&request=getcapabilities', CONST_GPS_URL_NORWAY_MAP: 'https://cache.kartverket.no/v1/wmts/1.0.0/WMTSCapabilities.xml',
CONST_GPS_DEFAULT_LATITUDE_NORWAY: 16, CONST_GPS_DEFAULT_LATITUDE_NORWAY: 16,
CONST_GPS_DEFAULT_LONGITUDE_NORWAY: 63, CONST_GPS_DEFAULT_LONGITUDE_NORWAY: 63,
......
...@@ -226,12 +226,10 @@ export default { ...@@ -226,12 +226,10 @@ export default {
let result = parser.read(text); let result = parser.read(text);
let options = optionsFromCapabilities(result, { let options = optionsFromCapabilities(result, {
layer: 'topo4', layer: 'topo',
matrixSet: 'EPSG:3857', matrixSet: 'webmercator',
}); });
//CommonUtil.logInfo(options); //CommonUtil.logInfo(options);
// Need to force https on the tiles URL (bug in the service?)
options.urls[0] = options.urls[0].replace("http", "https");
This.myMap = new Map({ This.myMap = new Map({
layers: [ layers: [
......
...@@ -147,10 +147,9 @@ export default { ...@@ -147,10 +147,9 @@ export default {
let result = parser.read(text); let result = parser.read(text);
let options = optionsFromCapabilities(result, { let options = optionsFromCapabilities(result, {
layer: 'topo4', layer: 'topo',
matrixSet: 'EPSG:3857', matrixSet: 'webmercator',
}); });
options.urls[0] = options.urls[0].replace("http","https");
This.myMap = new Map({ This.myMap = new Map({
layers: [ layers: [
......
...@@ -416,13 +416,10 @@ ...@@ -416,13 +416,10 @@
let parser = new WMTSCapabilities(); let parser = new WMTSCapabilities();
var result = parser.read(text); var result = parser.read(text);
var options = optionsFromCapabilities(result, { var options = optionsFromCapabilities(result, {
layer: 'topo4', layer: 'topo',
matrixSet: 'EPSG:3857', matrixSet: 'webmercator',
}); });
// Need to force https on the tiles URL (bug in the service?)
options.urls[0] = options.urls[0].replace("http","https");
This.map = new Map({ This.map = new Map({
layers: [ layers: [
new TileLayer({ new TileLayer({
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment