- prevent modify promotion store sku. lack callback handler
This commit is contained in:
@@ -5,6 +5,7 @@ import (
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"git.rosy.net.cn/jx-callback/business/jxutils"
|
||||
"git.rosy.net.cn/jx-callback/business/jxutils/jxcontext"
|
||||
"git.rosy.net.cn/jx-callback/business/jxutils/storeskulock"
|
||||
"git.rosy.net.cn/jx-callback/business/jxutils/tasksch"
|
||||
"git.rosy.net.cn/jx-callback/business/model"
|
||||
"git.rosy.net.cn/jx-callback/business/model/dao"
|
||||
@@ -69,7 +70,9 @@ func (p *PurchaseHandler) SyncStoreSkus(ctx *jxcontext.Context, parentTask tasks
|
||||
} else {
|
||||
alreadyAddStock = true
|
||||
}
|
||||
skuStockList = append(skuStockList, stock)
|
||||
if stock.StockQty != 0 || !storeskulock.IsJdStoreSkuLocked(storeID, storeSku.SkuID) {
|
||||
skuStockList = append(skuStockList, stock)
|
||||
}
|
||||
}
|
||||
if storeSku.JdSyncStatus&(model.SyncFlagPriceMask|model.SyncFlagNewMask) != 0 {
|
||||
skuPriceInfoList = append(skuPriceInfoList, &jdapi.SkuPriceInfo{
|
||||
@@ -91,7 +94,9 @@ func (p *PurchaseHandler) SyncStoreSkus(ctx *jxcontext.Context, parentTask tasks
|
||||
}
|
||||
skuStockList = append(skuStockList, stock)
|
||||
}
|
||||
skuVendibilityList = append(skuVendibilityList, vendibility)
|
||||
if vendibility.DoSale || !storeskulock.IsJdStoreSkuLocked(storeID, storeSku.SkuID) {
|
||||
skuVendibilityList = append(skuVendibilityList, vendibility)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user