diff --git a/business/partner/purchase/mtwm/order_comment.go b/business/partner/purchase/mtwm/order_comment.go index 2b62df78b..d8237e0ba 100644 --- a/business/partner/purchase/mtwm/order_comment.go +++ b/business/partner/purchase/mtwm/order_comment.go @@ -45,15 +45,14 @@ func formalizeTagList(mtwmTagList string) (outTagList string) { func (c *PurchaseHandler) RefreshComment(fromTime, toTime time.Time) (err error) { globals.SugarLogger.Debugf("--------------------------------------------------------------") - //storeMapList, err2 := dao.GetStoresMapList(dao.GetDB(), []int{model.VendorIDMTWM}, nil, nil, model.StoreStatusAll, model.StoreIsSyncYes, "", "", "") - //if err = err2; err != nil { - // return err - //} startTime := time.Now().Add(-24 * time.Hour) //endTime := time.Now().Add(-RefreshCommentTime) endDateStr := startTime.Format("20060102") startDateStr := time.Now().Add(-RefreshCommentTime).Format("20060102") storeIDs, _ := dao.GetOrderStoreIDs(dao.GetDB(), fromTime, toTime, model.VendorIDMTWM) + globals.SugarLogger.Debugf("------fromTime := %s", utils.Time2TimeStr(fromTime)) + globals.SugarLogger.Debugf("------toTime := %s", utils.Time2TimeStr(toTime)) + globals.SugarLogger.Debugf("------storeIDs := %s", utils.Format4Output(storeIDs, false)) task := tasksch.NewParallelTask("mtwm RefreshComment", nil, jxcontext.AdminCtx, func(task *tasksch.ParallelTask, batchItemList []interface{}, params ...interface{}) (retVal interface{}, err error) { storeID := batchItemList[0].(int) @@ -63,12 +62,10 @@ func (c *PurchaseHandler) RefreshComment(fromTime, toTime time.Time) (err error) return nil, nil } // 查询门店差评 + globals.SugarLogger.Debugf("------startDateStr := %s", startDateStr) + globals.SugarLogger.Debugf("------endDateStr := %s", endDateStr) commentList, err := getAPI(storeDetail.VendorOrgCode, storeID, storeDetail.VendorStoreID).CommentQuery(storeDetail.VendorStoreID, startDateStr, endDateStr, 0, 0, mtwmapi.CommentReplyStatusNotReplied) - globals.SugarLogger.Debugf("========commentList:%s", storeDetail.VendorStoreID) - globals.SugarLogger.Debugf("========commentList:%v", err) - if storeDetail.VendorStoreID == "23932637" { - globals.SugarLogger.Debugf("commentList --------------- := %s", utils.Format4Output(commentList, false)) - } + globals.SugarLogger.Debugf("commentList lenght --------------- := %s", utils.Format4Output(len(commentList), false)) var orderCommentList []*model.OrderComment if len(commentList) == model.NO || commentList == nil { return nil, nil