|
|
|
@@ -541,9 +541,9 @@ func QueryUserStaticDataPage(opts *UserBusinessAnalysisQueryOptions) ([]*UserBus |
|
|
|
statictisSess := xStatistic.NewSession() |
|
|
|
defer statictisSess.Close() |
|
|
|
|
|
|
|
currentTimeNow := time.Now() |
|
|
|
pageStartTime := getLastCountDate() |
|
|
|
pageEndTime := time.Date(currentTimeNow.Year(), currentTimeNow.Month(), currentTimeNow.Day(), 23, 59, 59, 0, currentTimeNow.Location()).Unix() |
|
|
|
//currentTimeNow := time.Now() |
|
|
|
//pageStartTime := getLastCountDate() |
|
|
|
//pageEndTime := time.Date(currentTimeNow.Year(), currentTimeNow.Month(), currentTimeNow.Day(), 23, 59, 59, 0, currentTimeNow.Location()).Unix() |
|
|
|
|
|
|
|
var cond = builder.NewCond() |
|
|
|
if len(opts.UserName) > 0 { |
|
|
|
@@ -552,10 +552,10 @@ func QueryUserStaticDataPage(opts *UserBusinessAnalysisQueryOptions) ([]*UserBus |
|
|
|
) |
|
|
|
} |
|
|
|
cond = cond.And( |
|
|
|
builder.Gte{"count_date": pageStartTime}, |
|
|
|
builder.Gte{"count_date": opts.StartTime}, |
|
|
|
) |
|
|
|
cond = cond.And( |
|
|
|
builder.Lte{"count_date": pageEndTime}, |
|
|
|
builder.Lte{"count_date": opts.EndTime}, |
|
|
|
) |
|
|
|
|
|
|
|
count, err := statictisSess.Where(cond).Count(new(UserBusinessAnalysis)) |
|
|
|
|