controllger.go 600 B

12345678910111213141516171819202122232425262728293031323334
  1. package label
  2. import (
  3. "net/http"
  4. "bet24.com/log"
  5. "github.com/gin-gonic/gin"
  6. )
  7. // 获取标签配置
  8. func GetConfigList(c *gin.Context) {
  9. configList := mgr.getConfigList()
  10. c.JSON(http.StatusOK, struct {
  11. RecordCount int
  12. List interface{}
  13. }{
  14. RecordCount: 0,
  15. List: configList,
  16. })
  17. return
  18. }
  19. // 留存统计
  20. func GetLiveStatList(c *gin.Context) {
  21. var req request_liveStatList
  22. if err := c.ShouldBind(&req); err != nil {
  23. log.Debug("%s shouldBind err %v", "label.GetLiveStatList", err)
  24. return
  25. }
  26. resp := mgr.getLiveStatList(req)
  27. c.JSON(http.StatusOK, resp)
  28. return
  29. }