京东商城

This commit is contained in:
苏尹岚
2020-05-14 17:00:40 +08:00
parent 946aad298d
commit 5b95a414ac

View File

@@ -82,7 +82,10 @@ func (p *PurchaseHandler) UpdateStoreSkus(ctx *jxcontext.Context, storeID int, v
func (p *PurchaseHandler) DeleteStoreSkus(ctx *jxcontext.Context, storeID int, vendorStoreID string, storeSkuList []*partner.StoreSkuInfo) (failedList []*partner.StoreSkuInfoWithErr, err error) {
if globals.EnableJdShopWrite && vendorStoreID == model.JdShopMainVendorStoreID {
for _, v := range storeSkuList {
err = api.JdShopAPI.DeleteWare(utils.Str2Int(v.VendorSkuID2))
err = api.JdShopAPI.UpOrDown(utils.Str2Int64(v.VendorSkuID2), 2)
if err == nil {
err = api.JdShopAPI.DeleteWare(utils.Str2Int(v.VendorSkuID2))
}
}
if err != nil {
failedList = putils.GetErrMsg2FailedSingleList(storeSkuList, err, storeID, model.VendorChineseNames[model.VendorIDJDShop], "删除商品")
@@ -308,16 +311,16 @@ func buildCreateWareParam(storeSku *dao.StoreSkuSyncInfo) (createSkuParamWare *j
ShopCategorys: []int{utils.Str2Int(storeSku.VendorCatID)},
CategoryID: int(storeSku.VendorVendorCatID),
BrandID: jdshopapi.JxBrandId,
TransportID: jdshopapi.TransportID,
WareStatus: 8, //上架待审核
OuterID: utils.Int2Str(storeSku.NameID),
VenderID: 0,
Length: 100,
Width: 100,
Height: 100,
Weight: 0.5,
JdPrice: jxutils.IntPrice2Standard(storeSku.UnitPrice),
MarketPrice: jxutils.IntPrice2Standard(storeSku.UnitPrice),
// TransportID: jdshopapi.TransportID,
WareStatus: 8, //上架待审核
OuterID: utils.Int2Str(storeSku.NameID),
VenderID: 0,
Length: 100,
Width: 100,
Height: 100,
Weight: 0.5,
JdPrice: jxutils.IntPrice2Standard(storeSku.UnitPrice),
MarketPrice: jxutils.IntPrice2Standard(storeSku.UnitPrice),
}
//上传京东图片