1
This commit is contained in:
@@ -193,6 +193,7 @@ func skuInfo2Param(ctx *jxcontext.Context, sku *dao.StoreSkuSyncInfo) (param *jd
|
||||
}
|
||||
|
||||
func (p *PurchaseHandler) CreateSku2(ctx *jxcontext.Context, sku *dao.StoreSkuSyncInfo) (err error) {
|
||||
globals.SugarLogger.Debugf("是不是正儿八经的京东商城%s", "CreateSku2")
|
||||
param := skuInfo2Param(ctx, sku)
|
||||
if globals.EnableJdStoreWrite {
|
||||
sku.VendorSkuID, err = getAPI(sku.VendorOrgCode).AddSku2(param)
|
||||
@@ -218,6 +219,7 @@ func (p *PurchaseHandler) CreateSku2(ctx *jxcontext.Context, sku *dao.StoreSkuSy
|
||||
}
|
||||
|
||||
func (p *PurchaseHandler) UpdateSku2(ctx *jxcontext.Context, sku *dao.StoreSkuSyncInfo) (err error) {
|
||||
globals.SugarLogger.Debugf("是不是正儿八经的京东商城%s", "UpdateSku2")
|
||||
param := skuInfo2Param(ctx, sku)
|
||||
if globals.EnableJdStoreWrite {
|
||||
_, err = getAPI(sku.VendorOrgCode).UpdateSku2(param)
|
||||
@@ -226,7 +228,7 @@ func (p *PurchaseHandler) UpdateSku2(ctx *jxcontext.Context, sku *dao.StoreSkuSy
|
||||
}
|
||||
|
||||
func (p *PurchaseHandler) DeleteSku2(ctx *jxcontext.Context, vendorOrgCode string, sku *partner.StoreSkuInfo) (err error) {
|
||||
|
||||
globals.SugarLogger.Debugf("是不是正儿八经的京东商城%s", "DeleteSku2")
|
||||
// 京东到家只能通过商家ID删除SKU,如果没有的话,先绑定,再删除
|
||||
if sku.SkuID == 0 {
|
||||
skuPairList := []*jdapi.SkuIDPair{
|
||||
|
||||
Reference in New Issue
Block a user