文档
测试

商品列表

POST
http://laiba.bxwhl.com/api/product/getGoodsList.html

请求参数

参数名
类型
描述
必填
page
int
页码 (默认获取第一页,每页10条) 可选
必填
category_id
int
分类ID ,用户获取某个分类下的商品 可选
必填
search
string
查询关键字 ,商品名称 可选
必填

响应参数

参数名
类型
描述
必填
code
必填
msg
必填
data
必填

说明 / 示例

```json { "code": 1, "msg": "获取成功", "data": { "total": 2, //总条数 "per_page": 10, //每页数量 "current_page": 1, //当前页 "last_page": 1, //共多少页 "data": [ { "id": 2798, //商品id "goods_name": "精酿原厂红酒", //商品名称 "goods_key": "22", "goods_unit": "22", "describe": "精酿原厂红酒", //商品描述 "goods_price": "1000.00", "line_price": "1000.00", "postage": "0.00", "spec_type": 0, "content": "<p>精酿原厂红酒</p>", "sales_initial": 22, "is_new": 1, "is_shop_commend": 1, "goods_status": 1, "is_delete": 0, "views": 7, "stock": 1000, "qrcode": null, "category": { "id": 422, "title": "医疗按摩" }, "image": { "file_path": "http://laiba.bxwhl.com/uploads/202102071751477d0cb3712.jpg" } }, { "id": 2795, "goods_name": "养生花茶", "goods_key": "阿道夫", "goods_unit": "啊", "describe": "养生花茶", "goods_price": "100.00", "line_price": "100.00", "postage": "0.00", "spec_type": 0, "content": "<p>养生花茶</p>", "sales_initial": 0, "is_new": 0, "is_shop_commend": 1, "goods_status": 1, "is_delete": 0, "views": 0, "stock": 100, "qrcode": null, "category": { "id": 426, "title": "裤子" }, "image": { "file_path": "http://laiba.bxwhl.com/uploads/20210208145638107b97407.jpg" } } ] } }