Mercurial > gemma
comparison pkg/controllers/routes.go @ 2803:46a9a7c1281f
Added GET /api/data/year-waterlevels/{gauge}/{year}
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Mon, 25 Mar 2019 18:37:13 +0100 |
parents | db1052bc162a |
children | 6f435a9558f2 |
comparison
equal
deleted
inserted
replaced
2801:054f5d61452d | 2803:46a9a7c1281f |
---|---|
306 middleware.DBConn(http.HandlerFunc(averageWaterlevels)))).Methods(http.MethodGet) | 306 middleware.DBConn(http.HandlerFunc(averageWaterlevels)))).Methods(http.MethodGet) |
307 | 307 |
308 api.Handle("/data/longterm-waterlevels/{gauge}", any( | 308 api.Handle("/data/longterm-waterlevels/{gauge}", any( |
309 middleware.DBConn(http.HandlerFunc(longtermWaterlevels)))).Methods(http.MethodGet) | 309 middleware.DBConn(http.HandlerFunc(longtermWaterlevels)))).Methods(http.MethodGet) |
310 | 310 |
311 api.Handle("/data/year-waterlevels/{gauge}/{year:[0-9]+}", any( | |
312 middleware.DBConn(http.HandlerFunc(yearWaterlevels)))).Methods(http.MethodGet) | |
313 | |
311 api.Handle("/data/nash-sutcliffe/{gauge}", any(&JSONHandler{ | 314 api.Handle("/data/nash-sutcliffe/{gauge}", any(&JSONHandler{ |
312 Handle: nashSutcliffe, | 315 Handle: nashSutcliffe, |
313 })).Methods(http.MethodGet) | 316 })).Methods(http.MethodGet) |
314 | 317 |
315 // Token handling: Login/Logout. | 318 // Token handling: Login/Logout. |