| | |
| | | "wms/request" |
| | | "wms/response" |
| | | "wms/service" |
| | | "wms/task" |
| | | ) |
| | | |
| | | type ReportFormsController struct { |
| | |
| | | |
| | | util.ResponseFormatList(c, code.Success, list, int(total)) |
| | | } |
| | | |
| | | // DoMonthStats |
| | | // @Tags 报表 |
| | | // @Summary 手动跑月度统计库存报表 |
| | | // @Produce application/json |
| | | // @Param object body request.DoMonthStats true "查询参数" |
| | | // @Param Authorization header string true "token" |
| | | // @Success 200 {object} util.ResponseList{data=[]models.MonthStats} "成功" |
| | | // @Router /api-wms/v1/forms/doMonthStats [post] |
| | | func (slf ReportFormsController) DoMonthStats(c *gin.Context) { |
| | | var params request.DoMonthStats |
| | | if err := c.BindJSON(¶ms); err != nil { |
| | | util.ResponseFormat(c, code.RequestParamError, "参数解析失败,数据类型错误") |
| | | return |
| | | } |
| | | |
| | | if params.Token != constvar.DoMonthStatsToken { |
| | | return |
| | | } |
| | | |
| | | task.MonthStats() |
| | | util.ResponseFormat(c, code.Success, nil) |
| | | } |