# HG changeset patch # User Bernhard Reiter # Date 1539012042 -7200 # Node ID 430d52c2f6ef60f30f1ae22c5da378a1156c398a # Parent e6220a19f28480fd5b4744bdea461588d4b7796e client: move layer isolines to be drawn at the top * Move layer isolones to be drawn last (and thus being "on top") so that the bottleneck (position) layer will not interfere that much with the colours. It also allows to set a white background with high opacity on the bottleneck polygon in order to get highly visible isolines. diff -r e6220a19f284 -r 430d52c2f6ef client/src/map/store.js --- a/client/src/map/store.js Mon Oct 08 15:18:26 2018 +0200 +++ b/client/src/map/store.js Mon Oct 08 17:20:42 2018 +0200 @@ -32,33 +32,6 @@ isVisible: true }, { - name: "Bottleneck isolines", - data: new TileLayer({ - source: new TileWMS({ - preload: 0, - projection: "EPSG:3857", - url: window.location.origin + "/api/internal/wms", - params: { - LAYERS: "sounding_results_contour_lines_geoserver", - VERSION: "1.1.1", - TILED: true - }, - tileLoadFunction: function(tile, src) { - // console.log("calling for", tile, src); - HTTP.get(src, { - headers: { - "X-Gemma-Auth": localStorage.getItem("token") - }, - responseType: "blob" - }).then(response => { - tile.getImage().src = URL.createObjectURL(response.data); - }); - } // TODO tile.setState(TileState.ERROR); - }) - }), - isVisible: true - }, - { name: "Fairway Dimensions", data: new VectorLayer({ source: new VectorSource(), @@ -195,6 +168,33 @@ }) }), isVisible: true + }, + { + name: "Bottleneck isolines", + data: new TileLayer({ + source: new TileWMS({ + preload: 0, + projection: "EPSG:3857", + url: window.location.origin + "/api/internal/wms", + params: { + LAYERS: "sounding_results_contour_lines_geoserver", + VERSION: "1.1.1", + TILED: true + }, + tileLoadFunction: function(tile, src) { + // console.log("calling for", tile, src); + HTTP.get(src, { + headers: { + "X-Gemma-Auth": localStorage.getItem("token") + }, + responseType: "blob" + }).then(response => { + tile.getImage().src = URL.createObjectURL(response.data); + }); + } // TODO tile.setState(TileState.ERROR); + }) + }), + isVisible: true } ], // note that some identified features may not have an id