This commit is contained in:
苏尹岚
2021-02-08 14:14:35 +08:00
parent 48e4f5962a
commit 530ea46779

View File

@@ -1833,7 +1833,7 @@ func UploadJdsImage(ctx *jxcontext.Context) (err error) {
)
storeMaps, _ := dao.GetStoresMapList(db, []int{model.VendorIDJD}, []int{667281}, nil, model.StoreStatusAll, model.StoreIsSyncAll, "", "", "320406")
things, _ := dao.GetThingMapList(db, model.ThingTypeSku, []int{model.VendorIDJD}, nil, []string{"320406"})
for i := 0; i < len(things)/50+1; i += 50 {
for i := 0; i < len(things); i += 50 {
var idList []*jdapi.SkuIdEntity
for j := i; j < 50*k; j++ {
if j == len(things)-1 {
@@ -1847,6 +1847,9 @@ func UploadJdsImage(ctx *jxcontext.Context) (err error) {
}
idLists = append(idLists, idList)
k++
if i >= len(things) {
break
}
}
task := tasksch.NewParallelTask("uuuuu", tasksch.NewParallelConfig().SetIsContinueWhenError(true), ctx,
func(task *tasksch.ParallelTask, batchItemList []interface{}, params ...interface{}) (retVal interface{}, err error) {