1
This commit is contained in:
@@ -292,6 +292,12 @@ 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) {
|
||||
if poiCode == "18698027" {
|
||||
globals.SugarLogger.Debugf("--------poiCode%s", poiCode)
|
||||
globals.SugarLogger.Debugf("--------foodCode%s", foodCode)
|
||||
globals.SugarLogger.Debugf("--------params:%s", utils.Format4Output(params, false))
|
||||
|
||||
}
|
||||
_, err = a.AccessAPI2("retail/initdata", false, utils.MergeMaps(map[string]interface{}{
|
||||
KeyAppPoiCode: poiCode,
|
||||
KeyAppFoodCode: foodCode,
|
||||
|
||||
@@ -194,8 +194,8 @@ func TestMap(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestRetailDat(t *testing.T) {
|
||||
err := api.RetailInitData("F71D0F0881A211ED9D81525400E86DC0", "26207799", "mtcode_1808750374413807658", map[string]interface{}{
|
||||
"app_food_code": "mtcode_1808750374413807658",
|
||||
err := api.RetailInitData("F71D0F0881A211ED9D81525400E86DC0", "18698027", "25008", map[string]interface{}{
|
||||
"app_food_code": "25008",
|
||||
"category_name": "活动",
|
||||
"common_attr_value": "[{\"attrId\":1200000135,\"attrName\":\"包装方式\",\"valueList\":[{\"setValue\":true,\"setValueId\":true,\"value\":\"散装\",\"valueId\":1300000232}]},{\"attrId\":1200000202,\"attrName\":\"品种\",\"valueList\":[{\"setValue\":true,\"setValueId\":true,\"value\":\"韭菜\",\"valueId\":1300003045}]}]",
|
||||
"description": "",
|
||||
@@ -361,7 +361,7 @@ func TestRetailSellStatus2(t *testing.T) {
|
||||
//根据分类id查询属性列表
|
||||
func TestCategoryAttrList(t *testing.T) {
|
||||
//result, err := api.CategoryAttrList(200002680)
|
||||
result, err := api.CategoryAttrList(400000717)
|
||||
result, err := api.CategoryAttrList(200002794)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user