Mercurial > gemma
comparison pkg/controllers/gauges.go @ 4243:d776110b4db0 json-handler-middleware
Made the de-serialized input of the JSON handler accessible via the context of the request.
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Thu, 22 Aug 2019 10:54:08 +0200 |
parents | 1458c9b0fdaa |
children | 4394daeea96a |
comparison
equal
deleted
inserted
replaced
4242:1458c9b0fdaa | 4243:d776110b4db0 |
---|---|
572 // } | 572 // } |
573 | 573 |
574 return values, nil | 574 return values, nil |
575 } | 575 } |
576 | 576 |
577 func nashSutcliffe( | 577 func nashSutcliffe(req *http.Request) (jr JSONResult, err error) { |
578 _ interface{}, | 578 |
579 req *http.Request, | |
580 ) (jr JSONResult, err error) { | |
581 gauge := mux.Vars(req)["gauge"] | 579 gauge := mux.Vars(req)["gauge"] |
582 | 580 |
583 var isrs *models.Isrs | 581 var isrs *models.Isrs |
584 if isrs, err = parseISRS(gauge); err != nil { | 582 if isrs, err = parseISRS(gauge); err != nil { |
585 return | 583 return |