文档
测试

评价列表

GET
http://test.luckyuan.net/api/mall/CommentList?goods_id=302&num=2

请求参数

参数名
类型
描述
必填
goods_id
int
商品ID 示例:302
必填
num
int
每页展示数量 商品详情页 传2 评论列表传10
必填
page
int
页码
必填

响应参数

参数名
类型
描述
必填
type
int
示例:1
必填
msg
string
示例:获取成功
必填
data
object
数据字典
必填
data
array
数据列表
必填
id
int
评论ID 示例:13
必填
user_id
int
用户ID 示例:16689
必填
shop_id
int
店铺ID 示例:1
必填
order_id
int
订单ID 示例:543
必填
goods_id
int
商品ID 示例:302
必填
stars
int
评论星级 示例:1
必填
content
string
评论内容
必填
is_reply
int
商家是否回复 0未回复 1已回复
必填
reply_content
object
商家回复内容
必填
created_at
string
评论时间 示例:2020-08-27 18:39:24
必填
avatar
string
用户头像
必填
nickname
string
昵称
必填
goods_specs
string
规格型号 示例:颜色26:属性3021; 型号26:属性3021;
必填
pic_arr
array
评论图片 数据列表
必填

说明 / 示例

{ "msg": "获取成功", "data": { "current_page": 1, "data": [ { "id": 13, "user_id": 16689, "shop_id": 1, "order_id": 543, "goods_id": 302, "stars": 1, "content": "评论测试评论测试评论测试评论测试评论测试评论测试评论测试", "is_reply": 0, "reply_content": null, "created_at": "2020-08-27 18:39:24", "updated_at": "2020-08-27 18:41:51", "avatar": "/uploads/user/20200702/602faad24e44bf40a644a3d068afe47e_5efda5fdbadb8.jpeg", "nickname": "4323-16689", "goods_specs": "颜色26:属性3021; 型号26:属性3021; ", "pic_arr": [ "2020-08-27-15985151030077.png", " 2020-08-27-15985151661523.png" ] }, { "id": 12, "user_id": 16688, "shop_id": 1, "order_id": 543, "goods_id": 302, "stars": 5, "content": "评论测试评论测试评论测试评论测试评论测试评论测试评论测试", "is_reply": 0, "reply_content": null, "created_at": "2020-08-27 18:33:41", "updated_at": "2020-08-27 18:41:50", "avatar": "/images/logo.jpg", "nickname": "4322-16688", "goods_specs": "颜色26:属性3021; 型号26:属性3021; ", "pic_arr": [ "2020-08-27-15985151030077.png", " 2020-08-27-15985151661523.png" ] } ], "first_page_url": "http://test.luckyuan.net/api/mall/CommentList?page=1", "from": 1, "last_page": 5, "last_page_url": "http://test.luckyuan.net/api/mall/CommentList?page=5", "next_page_url": "http://test.luckyuan.net/api/mall/CommentList?page=2", "path": "http://test.luckyuan.net/api/mall/CommentList", "per_page": "2", "prev_page_url": null, "to": 2, "total": 10 }, "type": 1 }