- update qty before price for updating jd store sku info
This commit is contained in:
@@ -109,12 +109,12 @@ func (p *PurchaseHandler) SyncStoreSkus(ctx *jxcontext.Context, parentTask tasks
|
||||
if len(skuVendibilityList) > 0 {
|
||||
_, err = api.JdAPI.BatchUpdateVendibility("", stationNo, skuVendibilityList, ctx.GetUserName())
|
||||
}
|
||||
if err == nil && len(skuPriceInfoList) > 0 {
|
||||
_, err = api.JdAPI.UpdateVendorStationPrice("", stationNo, skuPriceInfoList)
|
||||
}
|
||||
if err == nil && len(skuStockList) > 0 {
|
||||
_, err = api.JdAPI.BatchUpdateCurrentQtys("", stationNo, skuStockList, ctx.GetUserName())
|
||||
}
|
||||
if err == nil && len(skuPriceInfoList) > 0 {
|
||||
_, err = api.JdAPI.UpdateVendorStationPrice("", stationNo, skuPriceInfoList)
|
||||
}
|
||||
}
|
||||
if err == nil && len(batchSkuIDs) > 0 {
|
||||
db := dao.GetDB() // 多线程问题
|
||||
@@ -217,12 +217,12 @@ func (p *PurchaseHandler) syncStoreSkus(ctx *jxcontext.Context, parentTask tasks
|
||||
if len(skuVendibilityList) > 0 {
|
||||
_, err = api.JdAPI.BatchUpdateVendibility("", stationNo, skuVendibilityList, ctx.GetUserName())
|
||||
}
|
||||
if err == nil && len(skuPriceInfoList) > 0 {
|
||||
_, err = api.JdAPI.UpdateVendorStationPrice("", stationNo, skuPriceInfoList)
|
||||
}
|
||||
if err == nil && len(skuStockList) > 0 {
|
||||
_, err = api.JdAPI.BatchUpdateCurrentQtys("", stationNo, skuStockList, ctx.GetUserName())
|
||||
}
|
||||
if err == nil && len(skuPriceInfoList) > 0 {
|
||||
_, err = api.JdAPI.UpdateVendorStationPrice("", stationNo, skuPriceInfoList)
|
||||
}
|
||||
}
|
||||
if err == nil && len(batchSkuIDs) > 0 {
|
||||
db := dao.GetDB() // 多线程问题
|
||||
|
||||
Reference in New Issue
Block a user