This commit is contained in:
2026-05-12 13:45:08 +08:00
parent e81df5ce5a
commit 37d3461983
38 changed files with 1721 additions and 1113 deletions

View File

@@ -13,12 +13,12 @@ var Stat = &statService{}
func (s *statService) List(ctx context.Context, req *dto.ListModelStatReq) (res *dto.ListModelStatRes, err error) {
pageNum, pageSize := 1, 10
if req != nil && req.Page != nil {
if req.Page.PageNum > 0 {
pageNum = int(req.Page.PageNum)
if req != nil {
if req.PageNum > 0 {
pageNum = req.PageNum
}
if req.Page.PageSize > 0 {
pageSize = int(req.Page.PageSize)
if req.PageSize > 0 {
pageSize = req.PageSize
}
}
startDay, endDay := "", ""
@@ -37,4 +37,3 @@ func (s *statService) List(ctx context.Context, req *dto.ListModelStatReq) (res
}
return &dto.ListModelStatRes{List: list, Total: total}, nil
}