简介
获取用户订单列表
接口地址
/api/v1/user/orders
请求参数
名称 | 必须 | 描述 |
---|---|---|
uid | 是 |
会员ID |
status | 否 | 订单状态 |
page | 否 | 页码 默认为1 |
limit | 否 | 每页显示数量 默认为10 |
timestamp | 是 | 当前时间戳 |
sign | 是 | 签名结果,签名算法介绍请点击这里 |
返回结果
名称 | 描述 |
---|---|
total | 总数 |
last_page | 最后页码 |
current_page | 当前页面 |
per_page | 每页显示数量 |
data | 购物车信息 |
|--id | 订单ID |
|--order_sn | 订单号 |
|--user_id | 用户ID |
|--order_amount | 订单总额 |
|--goods_money | 商品总额 |
|--delivery_money | 快递费用 |
|--order_status | 订单状态 |
|--pay_status | 订单状态 |
|--delivery_status | 发货状态 |
|--pay_type | 支付方式 |
|--delivery_type | 快递方式 |
|--delivery_code | 快递单号 |
|--receive_name | 收货人姓名 |
|--receive_telephone | 收货手机 |
|--receive_province | 收货省份 |
|--receive_city | 收货城市 |
|--receive_district | 收货区县 |
|--receive_address | 收货地址 |
|--create_time | 创建时间 |
|--pay_time | 支付时间 |
|--delivery_time | 发货时间 |
|--close_time | 关闭时间 |
|--finish_time | 完成时间 |
|--refund_time | 退款时间 |
|--remark | 订单备注 |
|--order_status_format | 订单状态文本 |
|--pay_status_format | 支付状态文本 |
|--delivery_status_format | 发货状态文本 |
|--create_time_format | 创建时间格式化 |
|--pay_time_format | 支付时间格式化 |
|--delivery_time_format | 发货时间格式化 |
|--close_time_format | 关闭时间格式化 |
|--finish_time_format | 完成时间格式化 |
|--pay_type_format | 支付方式文本 |
|--delivery_type_format | 快递方式文本 |
|--goods | 订单商品数组对象 |
返回示例
{
"result": {
"total": 8,
"last_page": 1,
"current_page": 1,
"per_page": 15,
"data": [
{
"id": 8,
"user_id": 1,
"order_sn": "22061620315339560",
"out_trade_no": "",
"order_amount": "200.00",
"goods_money": "200.00",
"delivery_money": "0.00",
"order_status": 1,
"pay_status": 1,
"delivery_status": 0,
"pay_type": "balance",
"delivery_type": "",
"delivery_code": "",
"receive_name": "张三",
"receive_telephone": "18666666666",
"receive_province": 96,
"receive_city": 208,
"receive_district": 212,
"receive_address": "天堂路",
"create_time": 1655382713,
"pay_time": 1655383040,
"delivery_time": 0,
"close_time": 0,
"finish_time": 0,
"refund_time": 0,
"remark": "",
"order_status_format": "待发货",
"pay_status_format": "已支付",
"delivery_status_format": "待发货",
"create_time_format": "2022-06-16 20:31:53",
"pay_time_format": "2022-06-16 20:37:20",
"delivery_time_format": "",
"close_time_format": "",
"finish_time_format": "",
"pay_type_format": "余额支付",
"delivery_type_format": "",
"goods": [
{
"id": 8,
"order_id": 8,
"user_id": 1,
"goods_id": 1,
"goods_name": "高端网站模版",
"goods_image": "/uploads/202205/06/OeYo9xyaXP6v1R5cY3YdaxwYg1plkxERLqVf6GNw.png",
"market_price": "999.00",
"shop_price": "100.00",
"number": 2,
"goods_money": "200.00",
"created_at": "2022-06-16 20:31:53",
"updated_at": "2022-06-16 20:31:53"
}
]
},
{
"id": 7,
"user_id": 1,
"order_sn": "22051714391599903",
"out_trade_no": "",
"order_amount": "200.00",
"goods_money": "200.00",
"delivery_money": "0.00",
"order_status": 3,
"pay_status": 1,
"delivery_status": 1,
"pay_type": "balance",
"delivery_type": "yuantong",
"delivery_code": "YT65777777",
"receive_name": "张三",
"receive_telephone": "18666666666",
"receive_province": 96,
"receive_city": 208,
"receive_district": 212,
"receive_address": "天堂路",
"create_time": 1652769555,
"pay_time": 1652769564,
"delivery_time": 1653640275,
"close_time": 0,
"finish_time": 1655281836,
"refund_time": 0,
"remark": "",
"order_status_format": "已完成",
"pay_status_format": "已支付",
"delivery_status_format": "已发货",
"create_time_format": "2022-05-17 14:39:15",
"pay_time_format": "2022-05-17 14:39:24",
"delivery_time_format": "2022-05-27 16:31:15",
"close_time_format": "",
"finish_time_format": "2022-06-15 16:30:36",
"pay_type_format": "余额支付",
"delivery_type_format": "圆通速递",
"goods": [
{
"id": 7,
"order_id": 7,
"user_id": 1,
"goods_id": 1,
"goods_name": "高端网站模版",
"goods_image": "/uploads/202205/06/OeYo9xyaXP6v1R5cY3YdaxwYg1plkxERLqVf6GNw.png",
"market_price": "999.00",
"shop_price": "100.00",
"number": 2,
"goods_money": "200.00",
"created_at": "2022-05-17 14:39:15",
"updated_at": "2022-05-17 14:39:15"
}
]
}
]
},
"msg": "返回成功",
"code": 200
}