1
This commit is contained in:
@@ -270,7 +270,7 @@ func (p *PurchaseHandler) createOrUpdateStoreSkus(ctx *jxcontext.Context, storeI
|
||||
Supply7dayReturn: 0,
|
||||
Mobile: storeDetail.Tel1,
|
||||
Commit: true,
|
||||
Specs: "净重|" + fmt.Sprintf("%f", storeSku.SpecQuality) + storeSku.SpecUnit,
|
||||
Specs: "净重|" + utils.Float64ToStr(float64(storeSku.SpecQuality)) + storeSku.SpecUnit,
|
||||
NeedRechargeMode: false,
|
||||
SellChannel: []int64{0},
|
||||
StartSaleType: 0,
|
||||
@@ -313,11 +313,9 @@ func (p *PurchaseHandler) createOrUpdateStoreSkus(ctx *jxcontext.Context, storeI
|
||||
return nil, err
|
||||
}
|
||||
|
||||
globals.SugarLogger.Debugf("本地商品详情============%s,", utils.Format4Output(param, false))
|
||||
// 根据本地商品id获取线上商品是否存在,存在则只创建子商品
|
||||
var tiktokResultProductId int64 = 0
|
||||
skuMain, err := api.GetSkuDetailLocalID("", param.OuterProductId)
|
||||
globals.SugarLogger.Debugf("线上商品详情(主)============%s,", utils.Format4Output(skuMain, false))
|
||||
if err != nil { // 线上不存在创建
|
||||
tiktokResult, err := api.CreateStoreCommodity(param) // 创建主商品
|
||||
if err != nil {
|
||||
@@ -462,7 +460,6 @@ func (p *PurchaseHandler) createOrUpdateStoreSkus(ctx *jxcontext.Context, storeI
|
||||
//param.SaleLimitId = saleLimitId
|
||||
//param.StoreId = utils.Str2Int64(vendorStoreID)
|
||||
// 抖店创建商品
|
||||
globals.SugarLogger.Debugf("更新子商品=============%s", utils.Format4Output(param, false))
|
||||
if err := api.EditStoreCommodity(param); err != nil {
|
||||
failedList = putils.GetErrMsg2FailedSingleList(storeSkuList, err, storeID, model.VendorChineseNames[model.VendorIDDD], syncType)
|
||||
storeSku.VendorSkuID = utils.Int2Str(storeSku.SkuID)
|
||||
|
||||
Reference in New Issue
Block a user