1
This commit is contained in:
@@ -58,17 +58,17 @@ func CopyOnStoreSkuToOther(ctx *jxcontext.Context, fromVendorStoreId, toStoreId
|
||||
Sequence: v.Sequence,
|
||||
})
|
||||
if err != nil {
|
||||
globals.SugarLogger.Debug("err := RetailCatUpdate : %s", utils.Format4Output(err, false))
|
||||
globals.SugarLogger.Debugf("err := RetailCatUpdate : %s", utils.Format4Output(err, false))
|
||||
}
|
||||
if v.Children != nil && len(v.Children) != 0 {
|
||||
for _, c := range v.Children {
|
||||
if err := toApi.RetailCatUpdate(toStore.VendorStoreID, v.Name, &mtwmapi.Param4UpdateCat{
|
||||
CategoryCode: v.Code,
|
||||
if err := toApi.RetailCatUpdate(toStore.VendorStoreID, c.Name, &mtwmapi.Param4UpdateCat{
|
||||
//CategoryCode: v.Code,
|
||||
SecondaryCategoryCode: c.Code,
|
||||
SecondaryCategoryName: c.Name,
|
||||
Sequence: c.Sequence,
|
||||
}); err != nil {
|
||||
globals.SugarLogger.Debug("err := RetailCatUpdate Children : %s", utils.Format4Output(err, false))
|
||||
globals.SugarLogger.Debugf("err := RetailCatUpdate Children : %v", utils.Format4Output(err, false))
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -77,11 +77,12 @@ func CopyOnStoreSkuToOther(ctx *jxcontext.Context, fromVendorStoreId, toStoreId
|
||||
case 3:
|
||||
// 同步商品
|
||||
fromFoodList, err1 := fromApi.RetailListAll(utils.Int2Str(fromVendorStoreId))
|
||||
globals.SugarLogger.Debugf("RetailListAll : %s", utils.Format4Output(fromFoodList, false))
|
||||
if err1 != nil {
|
||||
globals.SugarLogger.Debug("RetailListAll : %s", utils.Format4Output(err, false))
|
||||
globals.SugarLogger.Debugf("RetailListAll : %s", utils.Format4Output(err, false))
|
||||
}
|
||||
if err := BatchInitData(ctx, fromFoodList, toApi, toStore.VendorStoreID); err != nil {
|
||||
globals.SugarLogger.Debug("BatchInitData : %s", utils.Format4Output(err, false))
|
||||
globals.SugarLogger.Debugf("BatchInitData : %s", utils.Format4Output(err, false))
|
||||
}
|
||||
}
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user