From 778782ba9fa6a567313446860bab2534f963ceac Mon Sep 17 00:00:00 2001 From: zouap Date: Wed, 24 Nov 2021 16:30:21 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: zouap --- models/user_business_analysis.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/models/user_business_analysis.go b/models/user_business_analysis.go index 80c36fc42..84b201441 100644 --- a/models/user_business_analysis.go +++ b/models/user_business_analysis.go @@ -337,7 +337,7 @@ func RefreshUserStaticAllTabel() { statictisSess := xStatistic.NewSession() defer statictisSess.Close() - + log.Info("delete all data from table: user_business_analysis_all") statictisSess.Exec("delete from user_business_analysis_all") currentTimeNow := time.Now() @@ -356,6 +356,7 @@ func RefreshUserStaticAllTabel() { Find(&userBusinessAnalysisList); err != nil { return } + log.Info("query all data from table: user_business_analysis,len=" + fmt.Sprint(len(userBusinessAnalysisList))) for _, userRecord := range userBusinessAnalysisList { log.Info("insert to UserBusinessAnalysisAll table,user id=" + fmt.Sprint(userRecord.ID)) allData := getAllData(userRecord.ID, statictisSess) @@ -373,6 +374,7 @@ func RefreshUserStaticAllTabel() { log.Info("insert all data failed." + err.Error()) } } + log.Info("refresh all data finished.") } func CounDataByDateAndReCount(wikiCountMap map[string]int, startTime time.Time, endTime time.Time, isReCount bool) error {