1
This commit is contained in:
@@ -76,22 +76,22 @@ func CopyOnStoreSkuToOther(ctx *jxcontext.Context, fromVendorStoreId, toStoreId
|
|||||||
}
|
}
|
||||||
|
|
||||||
case 3:
|
case 3:
|
||||||
i := offSet
|
//i := offSet
|
||||||
for {
|
//for {
|
||||||
// 同步商品
|
// // 同步商品
|
||||||
fromFoodList, err1 := fromApi.RetailListAll(utils.Int2Str(fromVendorStoreId), i)
|
// fromFoodList, err1 := fromApi.RetailListAll(utils.Int2Str(fromVendorStoreId), i)
|
||||||
if len(fromFoodList) == 0 || fromFoodList == nil {
|
// if len(fromFoodList) == 0 || fromFoodList == nil {
|
||||||
return nil, fmt.Errorf("fromFoodList 为空 %s ,i:= %d", utils.Format4Output(err1, false), i)
|
// return nil, fmt.Errorf("fromFoodList 为空 %s ,i:= %d", utils.Format4Output(err1, false), i)
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
if err := BatchInitData(ctx, fromFoodList, toApi, toStore.VendorStoreID); err != nil {
|
// if err := BatchInitData(ctx, fromFoodList, toApi, toStore.VendorStoreID); err != nil {
|
||||||
globals.SugarLogger.Debugf("BatchInitData : %s", utils.Format4Output(err, false))
|
// globals.SugarLogger.Debugf("BatchInitData : %s", utils.Format4Output(err, false))
|
||||||
}
|
// }
|
||||||
if len(fromFoodList) < 100 {
|
// if len(fromFoodList) < 100 {
|
||||||
break
|
// break
|
||||||
}
|
// }
|
||||||
i++
|
// i++
|
||||||
}
|
//}
|
||||||
|
|
||||||
}
|
}
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user