From 6782078f3cdb614887553a1fba1367aa214572de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=82=B9=E5=AE=97=E6=A5=A0?= Date: Mon, 28 Apr 2025 18:00:21 +0800 Subject: [PATCH] 1 --- business/jxstore/cms/store_sku.go | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/business/jxstore/cms/store_sku.go b/business/jxstore/cms/store_sku.go index ba9662c3d..8553d336a 100644 --- a/business/jxstore/cms/store_sku.go +++ b/business/jxstore/cms/store_sku.go @@ -6604,18 +6604,13 @@ func CopyMtToJd(ctx *jxcontext.Context, mtStoreID, mtOrgCode, jdStoreID, jdOrgCo // } //} case 1: - globals.SugarLogger.Debugf("-----------lens := %d", 1) //建商品 skuList := make([]*mtwmapi.AppFood, 0, 0) - for { - skuList2, _ := mtapi.RetailListAll(mtStoreID, 0) - globals.SugarLogger.Debugf("-----------lens2 := %d", len(skuList2)) + for i := 0; i < 9; i++ { + skuList2, _ := mtapi.RetailListAll(mtStoreID, i) skuList = append(skuList, skuList2...) - if len(skuList2) < 100 { - break - } } - globals.SugarLogger.Debugf("-----------lens3 := %d", len(skuList)) + globals.SugarLogger.Debugf("-----len := %d", len(skuList)) //skuList, _ := mtapi.RetailList(mtStoreID, 0, 2) task2 := tasksch.NewParallelTask("美团到京东, 建商品", tasksch.NewParallelConfig().SetIsContinueWhenError(true).SetParallelCount(1), ctx, func(task *tasksch.ParallelTask, batchItemList []interface{}, params ...interface{}) (retVal interface{}, err error) {