From 6ffa263efb3d54068a0398864885974044ddb3f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=82=B9=E5=AE=97=E6=A5=A0?= Date: Fri, 16 May 2025 10:22:07 +0800 Subject: [PATCH] 1 --- business/model/dao/dao_order_sku_financial.go | 1 + business/partner/purchase/mtwm/order_comment.go | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/business/model/dao/dao_order_sku_financial.go b/business/model/dao/dao_order_sku_financial.go index c1677df42..00bfe5392 100644 --- a/business/model/dao/dao_order_sku_financial.go +++ b/business/model/dao/dao_order_sku_financial.go @@ -38,6 +38,7 @@ func GetBadCommentOrderId(jxStoreId int, startTime, endTime time.Time, foodNameL return "", err } + globals.SugarLogger.Debugf("--------commentOrder := %s", utils.Format4Output(commentOrder, false)) // 全等于的话就是目标订单 vendorOrderIdList := make([]string, 0, 0) for _, v := range commentOrder { diff --git a/business/partner/purchase/mtwm/order_comment.go b/business/partner/purchase/mtwm/order_comment.go index ee3423dab..00dad240a 100644 --- a/business/partner/purchase/mtwm/order_comment.go +++ b/business/partner/purchase/mtwm/order_comment.go @@ -115,11 +115,10 @@ func (c *PurchaseHandler) RefreshComment(fromTime, toTime time.Time) (err error) vendorOrderID, _ := dao.GetBadCommentOrderId(storeDetail.ID, time.Now().Add(-RefreshCommentTime), startTime, nameList, nil) if vendorOrderID != "" { orderComment.VendorOrderID2 = vendorOrderID - } else { + } else if len(skuIdList) > 0 { vendorOrderID, _ = dao.GetBadCommentOrderId(storeDetail.ID, time.Now().Add(-RefreshCommentTime), startTime, nil, skuIdList) orderComment.VendorOrderID2 = vendorOrderID } - globals.SugarLogger.Debugf("-------foodNameList := %s,skuIdList := %s,vendorOrderID := %s", utils.Format4Output(foodNameList, false), utils.Format4Output(skuIdList, false), vendorOrderID) } orderCommentList = append(orderCommentList, orderComment) }