简要描述:

  • 返回用户的所有订单(包括 "已完成" & "已取消" & "待支付" & "待发货" & "待收货", 不包括"已删除"的订单)

请求域名:

请求URL:

GET/plugin.package-deliver.frontend.order.list.index

各状态订单接口 (已关闭.cancelled/ 待提货订单.waitDeliver/待付款订单.waitPay/已完成订单.Completed)

参数:

参数名 是否必须 类型 说明
pagesize int 分页 - 每页数量; 默认是 5
page int 分页 - 页码
keyword string 关键字搜索
group_id int 团购id

返回示例:

正确时返回:

{
    "result": 1,
    "msg": "ok",
    "data": {
        "total": 5, 
        "per_page": 5, 
        "current_page": 1, 
        "last_page": 1, 
        "next_page_url": null, 
        "prev_page_url": null, 
        "from": 1, 
        "to": 5, 
        "data": [
            {
                "id": 1, 
                "order_sn": "SH20170302032407269208", 
                "price": 480, 
                "goods_price": 600, 
		"goods_total":1,
                "status_name": "待收货", 
                "button_models": [
                    {
                        "name": "确认收货", 
                        "api": "/order/pay", 
                        "value": 1
                    }, 
                    {
                        "name": "查看物流", 
                        "api": "/order/op/", 
                        "value": 8
                    }
                ], 
                "has_many_order_goods": [
                    {
                        "goods_id": 1, 
                        "goods_price": "300.00", 
                        "total": 1, 
                        "price": 300, 
                        "thumb": "http://demo.yunzshop.com/attachment/images/sz_yi/3/2017/01/ckUQfl.jpg", 
                        "title": "外套"
                    }, 
                    {
                        "goods_id": 2, 
                        "goods_price": "100.00", 
                        "total": 3, 
                        "price": 300, 
                        "thumb": "http://demo.yunzshop.com/attachment/images/sz_yi/1/2017/03/9usdl9.jpg", 
                        "title": "T 恤"
                    }
                ]
            }, 
            {
                "id": 2, 
                "order_sn": "SH20170302032541822244", 
                "price": 1360, 
                "goods_price": 1700, 
                "status_name": "待付款", 
                "button_models": [
                    {
                        "name": "付款", 
                        "api": "/order/op/pay", 
                        "value": 1
                    }, 
                    {
                        "name": "取消订单", 
                        "api": "/order/op/cancelPay", 
                        "value": 9
                    }
                ], 
                "has_many_order_goods": [
                    {
                        "goods_id": 1, 
                        "goods_price": "300.00", 
                        "total": 4, 
                        "price": 1200, 
                        "thumb": "http://demo.yunzshop.com/attachment/images/sz_yi/3/2017/01/ckUQfl.jpg", 
                        "title": "外套"
                    }, 
                    {
                        "goods_id": 2, 
                        "goods_price": "100.00", 
                        "total": 5, 
                        "price": 500, 
                        "thumb": "http://demo.yunzshop.com/attachment/images/sz_yi/1/2017/03/9usdl9.jpg", 
                        "title": "T 恤"
                    }
                ],
				"address": {
					"address": "北京 北京市 门头沟区 测试",
					"mobile": "15219025049",
					"realname": "测试"
				},
				"dispatch_type_name": "快递",
				"shop_name": "门店-轻微的",
				"plugin_id": 32,
            }, 
        ]
    }
}

错误时返回:

  • 缺少访问参数 memberid
{
	"result": 0,
	"msg": "缺少访问参数",
	"data": []
}
  • 未找到数据
{
    "result": 0, 
    "msg": "未找到数据", 
    "data": [ ]
}

返回参数说明:

参数名 类型 说明
id int 订单 ID
order_sn string 订单号
price int 订单金额(实际支付)
goods_price int 商品金额
status_name string 订单状态
button_models array 按钮
button_models['name'] string 按钮文字
button_models['api'] string 按钮关联的 API 路径
button_models['value'] int 显示在 HTML 表单的 Value 值
has_many_order_goods array 该订单下的商品列表
has_many_order_goods['goods_id'] int 商品 ID
has_many_order_goods['goods_price'] int 商品价格
has_many_order_goods['total'] int 订单中该商品的数量
has_many_order_goods['price'] int 实际支付的该商品的总价
has_many_order_goods['title'] string 商品名称
has_many_order_goods['thumb'] string 商品图片
address.address string 订单地址
address.mobile string 收货人电话
address.realname string 收货人姓名
dispatch_type_name string 配方方式名称
shop_name string 店铺名称
plugin_id int 订单类型 0自营 92供应商 31、32门店

备注: