代理商订单信息
橙旭园儿童编程
获取订单列表
Method and URL Structure
| Method |
Method Resource URL |
Descriptions |
Authentications Required |
| GET |
/server/agents/orders/ |
订单列表 |
YES |
cURL Example
curl -H 'Authorization: Token db4b5deed80091404ec2a295076221cf1f814b3e' http://127.0.0.1:8000/server/agents/orders/
Response
{ "count":4, "next":null, "previous":null, "results":[{ "amount":"1000.00", "rent_course_id":"1", "channel":"alipay", "order_number":"17363432019903582736220007", "channel_display":"支付宝", "status":1, "status_display":"已付款", "is_done":false, "order_type_display":"租凭", "apple_product_id":null, "userinfo":"18516271364", "agent_number":"000123401", "create_time":"2019-03-14 17:54:12.167953", "course_info":{ "pk":1, "course_name":"编程思维", "category_display":"编程思维", "class_time":"2019-01-08 18:27", "teacher":"王小莉", "teacher_Avatar":"https://example.com/avatar.png", "amount":"1000.00", "sales_commission":"500.00", "current_time":"2019-03-14 17:54:12.167953", .... } },..]}
Response Data Description
| Name |
Description |
| order_number |
订单编号 |
| userinfo |
用户名 |
| status_display |
付款状态 |
| create_time |
付款时间 |
| agent_number |
代理商编号 |
| course_name |
课程名 |
| class_time |
开课时间 |
| sales_commission |
代理商销售佣金 |
订单详情
Method and URL Structure
| Method |
Method Resource URL |
Descriptions |
Authentications Required |
| GET |
/server/agents/order/${number}/ |
订单详情 |
YES |
Request Parameters
| Name |
Description |
Required |
Default |
| number |
订单号 |
YES |
|
cURL Example
curl -H 'Authorization: Token db4b5deed80091404ec2a295076221cf1f814b3e' -H 'Content-Type: application/json' http://127.0.0.1:8000/server/contest/order/17363432019903582736220007/
Response
{ "amount":"1000.00", "rent_course_id":"1", "channel":"alipay", "order_number":"17363432019903582736220007", "channel_display":"支付宝", "status":1, "status_display":"已付款", "is_done":false, "order_type_display":"租凭", "apple_product_id":null, "userinfo":"18516271364", "agent_number":"000123401", "create_time":"2019-03-14 17:54:12.167953", "course_info":{ "pk":1, "course_name":"编程思维", "category_display":"编程思维", "class_time":"2019-01-08 18:27", "teacher":"王小莉", "teacher_Avatar":"https://example.com/avatar.png", "amount":"1000.00", "sales_commission":"500.00", "current_time":"2019-03-14 17:54:12.167953", .... }}
代理商详情
Method and URL Structure
| Method |
Method Resource URL |
Descriptions |
Authentications Required |
| GET |
/server/agents/employee/${number}/ |
代理商详情 |
NO |
Request Parameters
| Name |
Description |
Required |
Default |
| number |
代理商编号 |
YES |
|
cURL Example
curl localhost:8000/server/agents/employee/000123401/
Response
{ "pk":1, "name":"a", "number":"000123401", "extra_amount":"1000.00"}