audit.go 466 B

12345678910111213141516171819202122
  1. package http
  2. import (
  3. "strconv"
  4. "go-common/library/ecode"
  5. "go-common/library/log"
  6. bm "go-common/library/net/http/blademaster"
  7. )
  8. func audit(c *bm.Context) {
  9. params := c.Request.Form
  10. buildStr := params.Get("build")
  11. mobiApp := params.Get("mobi_app")
  12. build, err := strconv.Atoi(buildStr)
  13. if err != nil {
  14. log.Error("stronv.ParseInt(%s) error(%v)", buildStr, err)
  15. c.JSON(nil, ecode.RequestErr)
  16. return
  17. }
  18. c.JSON(nil, auditSvc.Audit(c, mobiApp, build))
  19. }