简要描述:
- 搜索门店商品结果优化#1892
请求域名:
- http://xx.com
请求URL:
GET/route=plugin.store-cashier.frontend.store.store.get-store-goods-list
参数:
参数名 | 是否必须 | 类型 | 说明 |
---|---|---|---|
kwd | 否 | string | 搜索内容 |
lng | 否 | float | 坐标经度 |
lat | 否 | float | 坐标纬度 |
city_name | 否 | string | 城市名字 |
返回示例:
正确时返回:
{
result: 1,
msg: "ok",
data: {
current_page: 1,
data: [
{
store_id: 82,
goods_id: 992,
distance: 42,
id: 992,
thumb: "https://dev3.yunzmall.com/attachment/image/281a447a1da2236f18abe0e45524b16a.jpeg",
title: "门店13216 商品1",
min_price: "0.20",
max_price: "0.20",
has_option: 0,
show_sales: 65,
vip_level_status: {
status: 0,
word: "",
tips: ""
},
vip_price: "0.20",
vip_next_price: 0
},
{
store_id: 82,
goods_id: 975,
distance: 42,
id: 975,
thumb: "https://dev3.yunzmall.com/attachment/image/0f3d1c7ba26b370d69c66cfcae4898c5.jpg",
title: "门店157商品1",
min_price: "200.00",
max_price: "200.00",
has_option: 0,
show_sales: 18,
vip_level_status: {
status: 0,
word: "",
tips: ""
},
vip_price: "200.00",
vip_next_price: 0
},
],
first_page_url: "https://dev3.yunzmall.com/addons/yun_shop/api.php?page=1",
from: 1,
last_page: 6,
last_page_url: "https://dev3.yunzmall.com/addons/yun_shop/api.php?page=6",
next_page_url: "https://dev3.yunzmall.com/addons/yun_shop/api.php?page=2",
path: "https://dev3.yunzmall.com/addons/yun_shop/api.php",
per_page: 15,
prev_page_url: null,
to: 15,
total: 87
}
}
错误时返回:
{
"result": 0,
"msg": "获取失败"
}
返回参数说明:
参数名 | 类型 | 说明 |
---|---|---|
store_id | int | 门店id |
goods_id / id | str | 商品id |
distance | int | 距离:米,如果不传定位是不会有这个字段的 |
thumb | str | 商品图片 |
title | str | 商品标题 |
min_price | float | 最低价 |
max_price | float | 最高价 |
show_sales | int | 销量 |
vip_price | float | 会员价 |
vip_next_price | float | 下一级会员价 |
备注:
- 更多返回错误代码请看首页的错误代码描述