Mercurial > gemma
comparison pkg/controllers/surveys.go @ 5572:3b842e951317 surveysperbottleneckid
change use from name of bottleneck to its id.
author | Thomas Junk <thomas.junk@intevation.de> |
---|---|
date | Tue, 20 Jul 2021 17:07:51 +0200 |
parents | fc01cdaf056d |
children | 271888ef85bc |
comparison
equal
deleted
inserted
replaced
5472:9321d9fb719f | 5572:3b842e951317 |
---|---|
40 LEFT JOIN waterway.gauges AS g | 40 LEFT JOIN waterway.gauges AS g |
41 ON b.gauge_location = g.location AND s.date_info::timestamptz <@ g.validity | 41 ON b.gauge_location = g.location AND s.date_info::timestamptz <@ g.validity |
42 LEFT JOIN waterway.gauges_reference_water_levels AS r | 42 LEFT JOIN waterway.gauges_reference_water_levels AS r |
43 ON s.depth_reference = r.depth_reference | 43 ON s.depth_reference = r.depth_reference |
44 AND g.location = r.location AND g.validity = r.validity | 44 AND g.location = r.location AND g.validity = r.validity |
45 WHERE b.objnam = $1` | 45 WHERE b.bottleneck_id = $1` |
46 ) | 46 ) |
47 | 47 |
48 func listSurveys(req *http.Request) (jr mw.JSONResult, err error) { | 48 func listSurveys(req *http.Request) (jr mw.JSONResult, err error) { |
49 | 49 |
50 bottleneckName := mux.Vars(req)["bottleneck"] | 50 bottleneckName := mux.Vars(req)["bottleneck"] |