comparison pkg/controllers/routes.go @ 2962:8d825551bc72

Fairway availibity for bottlenecks: Started with fetchting the relevant data. TODO: Range calculations. WIP.
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Mon, 08 Apr 2019 16:38:57 +0200
parents 6f435a9558f2
children 19fc84a98479
comparison
equal deleted inserted replaced
2961:5bc941d9ec43 2962:8d825551bc72
296 waterwayAdmin(&JSONHandler{ 296 waterwayAdmin(&JSONHandler{
297 Handle: reviewImport, 297 Handle: reviewImport,
298 })).Methods(http.MethodPut) 298 })).Methods(http.MethodPut)
299 299
300 // Handler to serve data to the client. 300 // Handler to serve data to the client.
301 api.Handle("/data/bottleneck/availability/{objnam}", any(&JSONHandler{
302 Handle: bottleneckAvailabilty,
303 })).Methods(http.MethodGet)
301 304
302 api.Handle("/data/waterlevels/{gauge}", any( 305 api.Handle("/data/waterlevels/{gauge}", any(
303 middleware.DBConn(http.HandlerFunc(waterlevels)))).Methods(http.MethodGet) 306 middleware.DBConn(http.HandlerFunc(waterlevels)))).Methods(http.MethodGet)
304 307
305 api.Handle("/data/longterm-waterlevels/{gauge}", any( 308 api.Handle("/data/longterm-waterlevels/{gauge}", any(