diff --git a/platformapi/mtwmapi/retail.go b/platformapi/mtwmapi/retail.go index 725147ad..9a27303c 100644 --- a/platformapi/mtwmapi/retail.go +++ b/platformapi/mtwmapi/retail.go @@ -291,12 +291,10 @@ func handleRetailBatchResultByRegexp(result interface{}) (failedFoodList []*AppF // https://developer.waimai.meituan.com/home/myquestionDetail/6716 // 另外这个接口即使不指定operate_type为1,也可能报错:”商品spu名称在该店内分类中已存在“,原因就是已经存在两个相同的SKU了 func (a *API) RetailInitData(trackInfo, poiCode, foodCode string, params map[string]interface{}) (err error) { - result, err := a.AccessAPI2("retail/initdata", false, utils.MergeMaps(map[string]interface{}{ + _, err = a.AccessAPI2("retail/initdata", false, utils.MergeMaps(map[string]interface{}{ KeyAppPoiCode: poiCode, KeyAppFoodCode: foodCode, }, params), resultKeyData, trackInfo) - globals.SugarLogger.Debugf("--------result := %s", utils.Format4Output(result, false)) - globals.SugarLogger.Debugf("--------result err:= %v", err) return err } @@ -310,8 +308,6 @@ func (a *API) RetailBatchInitData(trackInfo, poiCode string, foodDataList []map[ if err == nil { failedFoodList, err = handleRetailBatchResult(result) } - globals.SugarLogger.Debugf("--------result := %s", utils.Format4Output(result, false)) - globals.SugarLogger.Debugf("--------result err:= %v", err) return failedFoodList, err } @@ -337,6 +333,8 @@ func (a *API) RetailSkuPrice(trackInfo, poiCode string, foodData []*BareStoreFoo if err == nil { failedFoodList, err = handleRetailBatchResult(result) } + globals.SugarLogger.Debugf("--------result err:= %v", err) + globals.SugarLogger.Debugf("--------result result:= %v", utils.Format4Output(result, false)) return failedFoodList, err }