商铺的订单
金色童年
商铺订单列表
Method and URL Structure
Method |
Resource URL |
GET |
/market/shop/orders/ |
cURL Example
curl http://localhost/market/shop/orders/
Response
{
"count":1,
"next":null,
"previous":null,
"results":[{
"pk":4,
"order":{
"amount":"499.50",
"channel":"alipay",
"order_number":"14925746808730462516430013",
"shipping_address":"山东青岛四方四方火车站",
"telephone":"12345678910",
"linkman":"张三",
"channel_display":"支付宝",
"status":1,
"use_point":true,
"consume_point":6,
"status_display":"已付款",
"is_done":false,
"tracking_number": "1234567890",
"shipper_name": "顺丰快递",
"shipper_code" "SF",
"bought_product_set":[{
"product":{
"pk":16,
"category":13,
"category_name":"商品分类第二",
"name":"商品第五",
"price":"99.90",
"desc":"",
"evaluation_data":{
"bad_count":0,
"count":0,
"middle_count":0,
"good_count":0
},
"cover":"",
"desc_files":"",
"file_list":[""],
"shop":null,
"use_point":true,
"only_point":false,
"point":0
},
"quantity":5,
"amount":"499.50",
"created":"2017-01-10T18:48:17.122868"
}..]
}..]
}
商铺订单
Method and URL Structure
Method |
Resource URL |
GET |
/market/shop/order/${pk} |
cURL Example
curl http://localhost/market/shop/order/4/
Response
{
"pk":4,
"order":{
"amount":"499.50",
"channel":"alipay",
"order_number":"14925746808730462516430013",
"shipping_address":"山东青岛四方四方火车站",
"telephone":"12345678910",
"linkman":"张三",
"channel_display":"支付宝",
"status":1,
"use_point":true,
"consume_point":6,
"status_display":"已付款",
"is_done":false,
"tracking_number": "1234567890",
"shipper_name": "顺丰快递",
"shipper_code" "SF",
"bought_product_set":[{
"product":{
"pk":16,
"category":13,
"category_name":"商品分类第二",
"name":"商品第五",
"price":"99.90",
"desc":"",
"evaluation_data":{
"bad_count":0,
"count":0,
"middle_count":0,
"good_count":0
},
"cover":"",
"desc_files":"",
"file_list":[""],
"shop":null,
"use_point":true,
"only_point":false,
"point":0
},
"quantity":5,
"amount":"499.50",
"created":"2017-01-10T18:48:17.122868"
}..]
}
}
商铺给订单发货
Method and URL Structure
Method |
Resource URL |
PUT |
/market/shop/order/deliver/${pk} |
Request Data
{
"tracking_number": "1234567890"
"shipper_name": "顺丰快递",
"shipper_code" "SF",
}
cURL Example
curl --X POST --data {} http://localhost/market/shop/order/deliver/4/
订单物流跟踪
Method and URL Structure
Method |
Resource URL |
GET |
/market/shop/order/tracking/${pk} |
cURL Example
curl --X GET http://localhost/market/shop/order/tracking/4/
Response Data
{
"Success":true,
"ShipperCode":"YD",
"LogisticCode":"3917551653360",
"State":"3",
"Traces":[{
"AcceptTime":"2017-01-07 23:26:52",
"AcceptStation":"到达: xxx中心分拨分部 发往:xxx分拨中心"
},
.....
{
"AcceptTime":"2017-01-09 13:52:00",
"AcceptStation":"到达:xxxx 由 已签收 签收"
}],
"EBusinessID":"1270798"
}