Mercurial > gemma
diff client/src/lib/classifications.js @ 4270:e4d6c6339cb4
identify_tool: accuracy legend improved
author | Thomas Junk <thomas.junk@intevation.de> |
---|---|
date | Tue, 27 Aug 2019 17:07:16 +0200 |
parents | fbe2f1aa2757 |
children | 30f26bf7ff24 |
line wrap: on
line diff
--- a/client/src/lib/classifications.js Tue Aug 27 15:51:05 2019 +0200 +++ b/client/src/lib/classifications.js Tue Aug 27 17:07:16 2019 +0200 @@ -16,7 +16,17 @@ const getGauge = f => { if (f.getId().indexOf("bottlenecks") > -1) { - return f.get("gauge_obj"); + const GaugeProxy = (function(feature) { + const gauge = feature.get("gauge_obj"); + const get = function(propName) { + if (gauge) return gauge.get(propName); + return feature.get(propName); + }; + return { + get: get + }; + })(f); + return GaugeProxy; } return f; };