From 4f2f58a81bfa651429b5504074a622263eca28c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=82=B9=E5=AE=97=E6=A5=A0?= Date: Fri, 21 Oct 2022 17:15:50 +0800 Subject: [PATCH] 1 --- business/partner/purchase/tiktok_store/store_sku2.go | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/business/partner/purchase/tiktok_store/store_sku2.go b/business/partner/purchase/tiktok_store/store_sku2.go index b485d49af..6501b4567 100644 --- a/business/partner/purchase/tiktok_store/store_sku2.go +++ b/business/partner/purchase/tiktok_store/store_sku2.go @@ -338,14 +338,19 @@ func (p *PurchaseHandler) createOrUpdateStoreSkus(ctx *jxcontext.Context, storeI // 创建子商品 temp, err := dao.QueryStoreBindInfo(storeDetail.ID) + globals.SugarLogger.Debugf("er2==============err创建子商品%s", utils.Format4Output(temp, false)) if err != nil || temp == nil || temp.TemplateID == 0 { // 运费模板 param.FreightId, err = GetDeliveryTemp(api, vendorStoreID, storeDetail) + globals.SugarLogger.Debugf("er2==============FreightId%s", utils.Format4Output(param.FreightId, false)) + globals.SugarLogger.Debugf("er2==============FreightId%s", utils.Format4Output(err, false)) if err != nil { return nil, err } // 获取门店限售模板 param.SaleLimitId, err = CreateSaleTemp(utils.Str2Int64(vendorStoreID), api) + globals.SugarLogger.Debugf("er2==============SaleLimitId%s", utils.Format4Output(param.SaleLimitId, false)) + globals.SugarLogger.Debugf("er2==============SaleLimitId%s", utils.Format4Output(err, false)) if err != nil { return nil, err } @@ -359,7 +364,8 @@ func (p *PurchaseHandler) createOrUpdateStoreSkus(ctx *jxcontext.Context, storeI TradeLimitID: param.SaleLimitId, } dao.WrapAddIDCULDEntity(param, "jxAdmin") - dao.CreateEntity(dao.GetDB(), &freightTemplate) + err = dao.CreateEntity(dao.GetDB(), &freightTemplate) + globals.SugarLogger.Debugf("er2==============CreateEntity%s", utils.Format4Output(err, false)) } else { param.FreightId = temp.TemplateID param.SaleLimitId = temp.TradeLimitID