京东商城修改,删除规格

This commit is contained in:
苏尹岚
2020-05-20 11:48:04 +08:00
parent 6df82d79a5
commit 45214ba928
3 changed files with 30 additions and 12 deletions

View File

@@ -1286,7 +1286,8 @@ func DeleteSku(ctx *jxcontext.Context, skuID int, userName string) (num int64, e
return 0, err
}
dao.Commit(db)
if _, err = SetStoreSkuSyncStatus2(db, nil, partner.GetSingleStoreVendorIDs(), []int{skuID}, model.SyncFlagDeletedMask); err == nil {
}
if num == 1 {
_, err = CurVendorSync.SyncSku(ctx, db, -1, sku.ID, false, false, userName)
}

View File

@@ -600,6 +600,11 @@ func syncStoreSkuNew(ctx *jxcontext.Context, parentTask tasksch.ITask, causeFlag
createList = createList[:]
createList = rList
}
if len(updateList) > 0 {
rList2 := changeList2Jds(updateList)
updateList = updateList[:]
updateList = rList2
}
}
task := tasksch.NewParallelTask("syncStoreSkuNew", tasksch.NewParallelConfig().SetParallelCount(1).SetIsContinueWhenError(isContinueWhenError2), ctx,
func(task *tasksch.ParallelTask, batchItemList []interface{}, params ...interface{}) (retVal interface{}, err error) {