This commit is contained in:
邹宗楠
2021-12-14 10:20:54 +08:00
parent 0250abce53
commit 53d2b60f0e

View File

@@ -254,22 +254,22 @@ func (p *PurchaseHandler) CreateStoreSkus(ctx *jxcontext.Context, storeID int, v
var (
vendorSkuID int64
isExd bool = false
customSkuID int64
customSkuID string
)
if strings.Contains(storeSku.StoreName, model.ExdStoreName) {
isExd = true
if storeSku.ExdSkuID == "" {
customSkuID = 0
customSkuID = "0"
} else {
customSkuID = utils.Str2Int64(storeSku.ExdSkuID)
customSkuID = "storeSku.ExdSkuID"
}
} else {
isExd = false
customSkuID = int64(storeSku.SkuID)
customSkuID = "storeSku.SkuID"
}
params := genSkuParamsFromStoreSkuInfo2(storeSku, true, isExd)
if globals.EnableEbaiStoreWrite {
strStoreID := utils.Int2Str(storeID)
strStoreID := "storeID"
if vendorSkuID, err = api.EbaiAPI.SkuCreate(ctx.GetTrackInfo(), strStoreID, customSkuID, params); err == nil && !isExd {
utils.AfterFuncWithRecover(5*time.Second, func() {
api.EbaiAPI.SkuShopCategoryMap(strStoreID, vendorSkuID, "", utils.Str2Int64(storeSku.VendorCatID), genSkuCatRank(storeSku))