comparison client/src/store/fairwayavailability.js @ 5249:d855426a6e5d new-fwa

Fixed frontend for sections and stretches in new FWA implementation. This fix is not very elegant, but at least it is correct.
author Sascha Wilde <wilde@intevation.de>
date Tue, 12 May 2020 22:55:10 +0200
parents 2f513505bc88
children 09ec6a748fca
comparison
equal deleted inserted replaced
5248:8c44b518141a 5249:d855426a6e5d
258 widthLimit2, 258 widthLimit2,
259 limitingFactor, 259 limitingFactor,
260 type 260 type
261 } = options; 261 } = options;
262 let { from, to } = options; 262 let { from, to } = options;
263 let name = feature.hasOwnProperty("properties") 263 let name = "";
264 ? feature.properties.bottleneck_id 264 if (type === TYPES.BOTTLENECK) {
265 : feature.get("bottleneck_id"); 265 name = feature.hasOwnProperty("properties")
266 ? feature.properties.bottleneck_id
267 : feature.get("bottleneck_id");
268 } else {
269 name = feature.hasOwnProperty("properties")
270 ? feature.properties.name
271 : feature.get("objnam");
272 }
266 [from, to] = getIntervallBorders(from, to, frequency); 273 [from, to] = getIntervallBorders(from, to, frequency);
267 let additionalParams = ""; 274 let additionalParams = "";
268 let endpoint = type; 275 let endpoint = type;
269 if (type === TYPES.BOTTLENECK) { 276 if (type === TYPES.BOTTLENECK) {
270 if (limitingFactor === LIMITINGFACTORS.DEPTH) 277 if (limitingFactor === LIMITINGFACTORS.DEPTH)