diff --git a/models/user_business_analysis.go b/models/user_business_analysis.go index 63b6a642d..b3f548156 100644 --- a/models/user_business_analysis.go +++ b/models/user_business_analysis.go @@ -159,10 +159,10 @@ func QueryUserStaticDataPage(opts *UserBusinessAnalysisQueryOptions) ([]*UserBus ) } cond = cond.And( - builder.Gte{"count_date": fmt.Sprint(pageStartTime)}, + builder.Gte{"count_date": pageStartTime.Unix()}, ) cond = cond.And( - builder.Lte{"count_date": fmt.Sprint(pageEndTime)}, + builder.Lte{"count_date": pageEndTime.Unix()}, ) count, err := statictisSess.Where(cond).Count(new(UserBusinessAnalysis)) @@ -202,10 +202,10 @@ func QueryUserStaticDataPage(opts *UserBusinessAnalysisQueryOptions) ([]*UserBus newOrCond, ) newAndCond = newAndCond.And( - builder.Gte{"count_date": fmt.Sprint(opts.StartTime)}, + builder.Gte{"count_date": opts.StartTime}, ) newAndCond = newAndCond.And( - builder.Lte{"count_date": fmt.Sprint(opts.EndTime)}, + builder.Lte{"count_date": opts.EndTime}, ) userBusinessAnalysisList = make([]*UserBusinessAnalysis, 0)