diff --git a/docs/Reference/admin/category/category.md b/docs/Reference/admin/category/category.md new file mode 100644 index 0000000..666a3e1 --- /dev/null +++ b/docs/Reference/admin/category/category.md @@ -0,0 +1,795 @@ +# 品类-相关的接口文档 + +# 获取C端/B端顶级品类的列表 + +### URL + +GET /adminsys/category/l1/list/ + +### 请求参数 + +| 参数名称 | 参数类型 | 含义 | +| -------- | -------- | ------ | +| optrator | Int | 端种类 | + +### 应答 + +| 字段 | 类型 | 含义 | +| --------- | ------- | ---- | +| top_types | List of | | + +### 注释 + +| 值 | 含义 | +| ---- | ---- | +| 0 | C端 | +| 1 | B端 | + +### 请求例 + +```http +GET /adminsys/category/l1/list/?operator=1 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "result": 200, + "top_types": [ + { + "id": 6, + "t_top_name": "废铁", + "in_use": true, + "operator": 1, + "create_time": "1543906611", + "icon": null, + "icon_selected": null, + "ordering": 10, + "description": "", + "display": false + }, + { + "id": 14, + "t_top_name": "有色金属", + "in_use": true, + "operator": 1, + "create_time": "1543907051", + "icon": null, + "icon_selected": null, + "ordering": 9, + "description": "", + "display": false + }, + ] + }, + "context": null +} +``` + +# 获取二级品类的列表 + +### URL + +GET /adminsys/category/l2/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ----------- | ------------ | +| unbound | nullboolean | 未绑定 | +| id | Int | 顶级品类的ID | + +### 应答 + +| 字段 | 类型 | 含义 | +| --------- | ------- | ---- | +| sub_types | List of | | + +### 注释 + +unbound + +``` +TRUE_VALUES = { + 't', 'T', + 'y', 'Y', 'yes', 'YES', + 'true', 'True', 'TRUE', + 'on', 'On', 'ON', + '1', 1, + True +} + +FALSE_VALUES = { + 'f', 'F', + 'n', 'N', 'no', 'NO', + 'false', 'False', 'FALSE', + 'off', 'Off', 'OFF', + '0', 0, 0.0, + False + } + +NULL_VALUES = {'null', 'Null', 'NULL', '', None} +``` + +| 值 | 含义 | +| ------------------- | -------- | +| TRUE_VALUES中的元素 | 已经绑定 | +| FALSE_VALUE中的元素 | 没有绑定 | +| NULL_VALUES | 值为空 | + +### 请求例 + +```http +GET /adminsys/category/l2/list/?unbound=T&id=6 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "result": 200, + "sub_types": [ + { + "id": 114, + "unit": 1, + "t_sub_name": "测试", + "in_use": true, + "price_default_flow": "0.000", + "price_default_fix": "0.000", + "create_time": "1548430595", + "update_time": "1552312816", + "to_kg_scale": "1.0000", + "has_tax": true + }, + { + "id": 115, + "unit": 2, + "t_sub_name": "测试", + "in_use": true, + "price_default_flow": "0.000", + "price_default_fix": "0.000", + "create_time": "1548430616", + "update_time": "1552312816", + "to_kg_scale": "1.0000", + "has_tax": true + } + ] + }, + "context": null +} +``` + +# 对B端/C端的顶级品类进行增删改的接口 + +### URL + +POST /adminsys/category/l1/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------------- | -------------- | +| top_type | Flatten(DICT) | 新增的品类信息 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ------------ | +| id | Int | 顶级品类的ID | + +### 请求例 + +```http +POST /adminsys/category/l1/ +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data": { + "top_type": { + "t_top_name": "废铜", + "operator": 1, + "icon_selected": null, + "description": "就是废铁", + "display": false, + "ordering": 1 + } + } +} + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200, + "id": 49 + }, + "context": null +} + +***** + +### URL + +``` +PUT /adminsys/category/l1/ +``` + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ---------------- | +| id | Int | 顶级品类ID | +| update | DICT | 更新的品类的信息 | + +### 应答 + +无 + +### 请求例 + +```http +PUT /adminsys/category/l1/ +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "id":49, + "update":{ + "t_top_name": "废铜烂铁", + "operator": 1, + "icon_selected": null, + "description": "就是废铁", + "display": false, + "ordering": 3 + } + } +} +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +**** + +### URL + +DELETE /adminsys/category/l1/?id=6 + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | -------------- | +| id | Int | 要删除的品类ID | + +### 应答 + +无 + +### 请求例 + +```http +DELETE /adminsys/category/l1/?id=49 +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +### 注释 + +此处的删除是软删除,品类数据不会被删除掉,而是通过修改品类是否在使用的状态来判断该品类是否存在。 + +delete是将in_use =True 改成 False,前端将不展示False的这条数据。 + +# B端/C端二级品类增删改的接口 + +### URL + +POST /adminsys/category/l2/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | -------------------------- | +| sub_type | DICT | 要增加的二级品类的商品信息 | + +### 应答 + +| 响应参数 | 类型 | 含义 | +| -------- | ---- | ---------- | +| id | Int | 二级品类ID | + +### 请求例 + +```http +POST /adminsys/category/l2/ +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "sub_type":{ + "toptype_b_id":8, + "unit":"2", + "t_sub_name": "葵花皮皮2", + "in_use": true, + "price_default_flow": "15.000", + "price_default_fix": "16.000", + "update_time": "1552312816", + "to_kg_scale": "1.0000", + "has_tax": true + } +} +} +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200, + "id": 137 + }, + "context": null +} + +**** + +### URL + +PUT /adminsys/category/l2/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| ------------- | ------- | ------------------------ | +| id | Int | 二级品类的ID | +| update | DICT | 要更新的二级品类的信息 | +| refresh_price | Boolean | 是否刷新价格(默认不刷新) | + +### 应答 + +无 + +### 请求例 + +```http +PUT /adminsys/category/l2/ +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "id":8, + "update":{ + "unit":1, + "t_sub_name": "葵花皮皮3", + "in_use": true, + "price_default_flow": "0.000", + "price_default_fix": "0.000", + "create_time": "1548430595", + "update_time": "1552312816", + "to_kg_scale": "1.0000", + "has_tax": "false" + } +} +} + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +### 注释 + +修改接口的update内的所有字段均为可选,更新方式为增量式更新 + +例如:update下不含unit,则该次更新不对数据库中对应数据的unit做更新。 + +**** + +### URL + +DELETE /adminsys/category/l2/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ---------------- | +| id | Int | 二级品类的商品ID | + +### 应答 + +无 + +### 请求例 + +```http +DELETE /adminsys/category/l2/?id=8 + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +### 注释 + +此处的删除是软删除,品类数据不会被删除掉,而是通过修改品类是否在使用的状态来判断该品类是否存在。 + +delete是将in_use =True 改成 False,前端将不展示False的这条数据。 + +### B端/C端的顶级品类排序接口 + +### URL + +POST /adminsys/category/l1/ordering/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------ | ------------ | +| oo | Choice | 订单操作 | +| id | Int | 顶级品类的ID | + +### 应答 + +无 + +### 注释 + +| 值 | 含义 | +| ---- | ---- | +| -1 | 下移 | +| 1 | 上移 | + +### 请求例 + +```http +POST /adminsys/category/l1/ordering/ +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "id":36, + "oo":-1 +} +} + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +### 注释 + +增加接口的post内的所有的字段均是必填字段,通过修改这个oo的值来改变该商品的一个排序位置。 + +# B端/C端二级品类排序接口 + +### URL + +POST /adminsys/category/l2/ordering/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------ | ------------ | +| oo | Choice | 订单操作 | +| id | Int | 顶级品类的ID | + +### 应答 + +无 + +### 注释 + +| 值 | 含义 | +| ---- | ---- | +| -1 | 下移 | +| 1 | 上移 | + +### 请求例 + +```http +POST /adminsys/category/l2/ordering/ +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "id":9, + "oo":1 +} +} + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +### 注释 + +增加接口的post内的所有的字段均是必填字段,通过修改这个oo的值来改变该商品的一个排序位置。 + +二级品类要想通过post来新增数据的时候要满足两个条件,自身的is_use和其父(顶级品类)的is_use必须是true才能增加成功。 + +# 获取品类回收站列表 + +### URL + +GET /adminsys/category/recycle_bin/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------------- | ---- | ------------------------- | +| recycle_bin_id | Int | 回收站的ID | +| toptype | Int | B端商品品类的ID(默认None) | + +### 响应参数 + +| 响应字段 | 类型 | 含义 | +| -------- | ---- | ---------------- | +| products | DICT | 业务品类绑定信息 | + +### 请求例 + +```http +GET /adminsys/category/recycle_bin/?recycle_bin_id=1&toptype_id=12/ +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "products": [ + { + "p_type__id": 119, + "p_type__t_sub_name": "新版本", + "price": "0.000", + "modified_time": "1554098348", + "p_type__unit": 2, + "p_type_id": 119, + "recycle_bin_id": 1, + "p_type__to_kg_scale": "1.0000" + }, + { + "p_type__id": 104, + "p_type__t_sub_name": "断桥铝", + "price": "5.500", + "modified_time": "1554098347", + "p_type__unit": 1, + "p_type_id": 104, + "recycle_bin_id": 1, + "p_type__to_kg_scale": "1.0000" + }, + { + "p_type__id": 105, + "p_type__t_sub_name": "杂铝", + "price": "5.500", + "modified_time": "1554098347", + "p_type__unit": 1, + "p_type_id": 105, + "recycle_bin_id": 1, + "p_type__to_kg_scale": "1.0000" + }, + ], + "result": 200 + }, + "context": null +} +``` + +# 未绑定品类的回收站接口 + +### URL + +GET /adminsys/category/recycle_bin/unbound/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------------- | ---- | ------------------------- | +| recycle_bin_id | Int | 回收站的ID | +| toptype | Int | B端商品品类的ID(默认None) | + +### 响应参数 + +| 响应字段 | 类型 | 含义 | +| -------- | ---- | --------------------- | +| products | DICT | B端未绑定二级品类信息 | + +### 请求例 + +```http +GET /adminsys/category/recycle_bin/unbound/?recycle_bin_id=19 +``` + +### 应答例 + +暂无 + +# 品类回收站增删改的接口 + +### URL + +POST /adminsys/category/recycle_bin/product/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ---------------------- | +| product | DICT | 要增加的回收站品类信息 | + +### 应答 + +| 响应字段 | 类型 | 含义 | +| -------- | ---- | ---------- | +| id | Int | 新的品类ID | + +### 请求例 + +```http +POST /adminsys/category/recycle_bin/product/?user_sid=foch09x9nbgmb6q6ee1s48dnkedkqrvv +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "product":{ + "p_type__id": 42, + "p_type__t_sub_name": "测试BPTB", + "price": "1.200", + "p_type__unit": 3, + "p_type_id": 6, + "recycle_bin_id": 1, + "p_type__to_kg_scale": "1.0000" + } + } +} + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200, + "id": 1991 + }, + "context": null +} + +### URL + +PUT /adminsys/category/recycle_bin/product/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | -------------------- | +| id | Int | 已绑定的二级品类的ID | +| update | DICT | 要更新的品类信息 | + +### 响应参数 + +无 + +### 请求例 + +```http +POST /adminsys/category/recycle_bin/product/?user_sid=foch09x9nbgmb6q6ee1s48dnkedkqrvv +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "id":562, + "update":{ + "p_type__id": 42, + "p_type__t_sub_name": "测试BPTB", + "price": "1.200", + "p_type__unit": 3, + "p_type_id": 6, + "recycle_bin_id": 2, + "p_type__to_kg_scale": "1.0000" + } + } +} +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +### URL + +DELETE /adminsys/category/recycle_bin/product/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | -------------------- | +| id | Int | 已绑定的二级品类的ID | + +### 响应参数 + +无 + +### 请求例 + +```http +GET /adminsys/category/recycle_bin/product/?user_sid=foch09x9nbgmb6q6ee1s48dnkedkqrvv&id=562 +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} \ No newline at end of file diff --git a/docs/Reference/admin/category/category_busniess.md b/docs/Reference/admin/category/category_busniess.md new file mode 100644 index 0000000..e69de29 diff --git a/docs/Reference/admin/category/category_qc.md b/docs/Reference/admin/category/category_qc.md new file mode 100644 index 0000000..42e3874 --- /dev/null +++ b/docs/Reference/admin/category/category_qc.md @@ -0,0 +1,326 @@ +# 场地端全局品类相关接口(4-3-3) + +## 获取场地端全局品类的列表 + +### URL + +```http +GET /adminsys/category/qc/list/ +``` + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ---------------------- | +| id | Int | 顶级品类ID(默认为None) | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| --------- | ---- | ------------------------ | +| sub_types | List | 顶级品类下的二级品类信息 | + +### 请求例 + +获取ID=33的顶级品类下的二级品类信息 + +```http +GET /adminsys/category/qc/list/?id=33 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "result": 200, + "sub_types": [ + { + "id": 30, + "name": "铝合金", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + }, + { + "id": 31, + "name": "断桥铝", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + }, + { + "id": 32, + "name": "杂铝", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + }, + { + "id": 33, + "name": "件铝", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + }, + { + "id": 34, + "name": "白钢(304)", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + }, + { + "id": 35, + "name": "白钢(316)", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + }, + { + "id": 36, + "name": "白钢(201)", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + }, + { + "id": 37, + "name": "白钢(301)", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + }, + { + "id": 38, + "name": "白钢(430)", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + }, + { + "id": 39, + "name": "红铜", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + }, + { + "id": 40, + "name": "黄铜", + "unit": 1, + "price_default": "1.000", + "has_tax": true, + "in_use": true, + "toptype_id": 33 + } + ] + }, + "context": null +} +``` + +--- + +## 场地全局品类的增删改接口 + +### URL + +```http +POST /adminsys/category/qc/ +``` + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | -------------------- | +| sub_type | DICT | 要添加的二级品类信息 | + +### 应答 + +无 + +### 注释 + +sub_type中必填字段 + +| 字段名 | 类型 | 含义 | +| ---------- | ------- | ------------ | +| toptype_id | Int | 顶级品类ID | +| name | String | 二级品类名称 | +| unit | Int | 单位 | +| has_tax | Boolean | 是否含税 | + +### 请求例 + +```http +POST /adminsys/category/qc/?user_sid=s27hk7ox4omne17xiuyg4wvecplz37ae HTTP 1.1 +Host: - +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "sub_type":{ + "toptype_id":33, + "name":"花岗岩", + "unit":2, + "has_tax":"true" + } + } +} + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200, + "id": 48 + }, + "context": null +} + +--- + +### URL + +```http +PUT /adminsys/category/qc/ +``` + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| ------------- | ------- | -------------------------- | +| id | Int | QC端的商品ID(二级商品的ID) | +| update | DICT | 更新的数据信息 | +| refresh_price | Boolean | 是否刷新价格 | + +### 应答 + +无 + +### 请求例 + +```http +GET /adminsys/category/qc/?user_sid=s27hk7ox4omne17xiuyg4wvecplz37ae +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "id":48, + "update":{ + "name":"小红同学" + }, + "refresh_price":"true" + } +} + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +--- + +### URL + +```HTTP +DELETE /adminsys/category/qc/ +``` + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ---------- | +| id | Int | 二级品类ID | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| -------- | ------- | -------- | +| in_use | Boolean | 是否在用 | + +### 注释 + +DELETE接口是软删除,通过将正在用的二级品类的in_use修改成False,来代表删除。in_use=False的商品是不进行显示的。 + +## 场地端全局品类排序 + +### URL + +POST /adminsys/category/qc/ordering/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------ | ------------ | +| id | Int | 二级品类的ID | +| oo | Choice | 上移或这下移 | + +### 注释 + +oo + +| 值 | 含义 | +| ---- | ---- | +| 1 | 上移 | +| -1 | 下移 | + +### 请求例 + +```http +POST /adminsys/category/qc/ordering/? +user_sid=8p2r7n015e8y2i1awjdsylmw89uuot4o +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "id":47, + "oo":1 + } +} + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} \ No newline at end of file diff --git a/docs/Reference/admin/credential/credential.md b/docs/Reference/admin/credential/credential.md new file mode 100644 index 0000000..dfe463b --- /dev/null +++ b/docs/Reference/admin/credential/credential.md @@ -0,0 +1,618 @@ +# 装车单相关接口 + +## 获取装车单列表(3-1-1) + +### URL + +GET /adminsys/credential/lc/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| ------------------ | --------------------- | -------------- | +| user_sid | String | 会话 | +| page | Int(Optional) | 页码 | +| count_per_page | Int(Optional) | 每页条目数 | +| extra_filter | String(Optional) | 过滤器 | +| plate_number | String(Optional) | 汇总数 | +| is_qc_passed | NullBoolean(Optional) | 是否通过了质检 | +| start_time_loading | Timestamp(Optional) | 装车开始时间 | +| end_time_loading | Timestamp(Optional) | 装车结束时间 | +| start_time_qc | Timestamp(Optional) | 质检开始时间 | +| end_time_qc | Timestamp(Optional) | 质检结束时间 | +| recycle_bin_name | String(Optional) | 回收站名 | +| lc_qc_filter | String(Optional) | 质检员的名字 | +| id | Int(Optional) | 装车单ID | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ----------------- | ---- | -------------------- | +| n_pages | Int | 页码数 | +| credentials | List | 装车单相关信息 | +| count_qc_password | Int | 通过质检的装车单数量 | +| count_all | Int | 装车单总数量 | + +### 注释 + +lc_x_qc__lc_state + +| 值 | 含义 | +| --------- | ---------- | +| created | 创建装车单 | +| loaded | 已装车 | +| arrived | 已送达 | +| received | 已收货 | +| checking | 过磅中 | +| checked | 已审核 | +| reviewing | 复核中 | +| reviewed | 已复核 | +| qc_passed | 检验通过 | + + + +### 请求例 + +获取通过质检的装车单,每页3个,取第二页 + +```http +GET /adminsys/credential/lc/list/?page=1&count_per_page=3&lc_x_qc__lc_state=T +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "n_pages": 21, + "credentials": [ + { + "total_price_qc": 1111.0, + "recycle_bin__r_b_type": "flow", + "total_price": 79.2, + "qc_passed_date": 1554120278, + "user__recycling_staff_info__rs_name": "流三", + "lc_x_qc__lc_state": "qc_passed", + "trigger_alert": true, + "id": 70, + "truck__number_plate": "ZZZZZZ", + "user__pn": "15666666666" + }, + { + "total_price_qc": 666.0, + "recycle_bin__r_b_type": "flow", + "total_price": 1332.0, + "qc_passed_date": 1554120149, + "user__recycling_staff_info__rs_name": "流三", + "lc_x_qc__lc_state": "qc_passed", + "trigger_alert": true, + "id": 69, + "truck__number_plate": "33333", + "user__pn": "15666666666" + }, + { + "total_price_qc": 33.0, + "recycle_bin__r_b_type": "flow", + "total_price": 14.0, + "qc_passed_date": 1554106512, + "user__recycling_staff_info__rs_name": "流三", + "lc_x_qc__lc_state": "qc_passed", + "trigger_alert": true, + "id": 68, + "truck__number_plate": "AAA", + "user__pn": "15666666666" + } + ], + "count_all": 62, + "count_qc_passed": 19, + "result": 200 + }, + "context": null +} +``` + +## 装车单基本信息接口(3-1-1-1) + +### URL + +GET /adminsys/credential/lc/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | -------- | +| id | Int | 装车单ID | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ---------- | ---- | -------------- | +| credential | DICT | 装车单基本信息 | + +### 请求例 + +获取id为70的装车单信息 + +```http +GET /adminsys/credential/lc/?id=70 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "credential": { + "recycle_bin__r_b_type": "flow", + "user__recycling_staff_info__rs_name": "流三", + "lc_x_qc__lc_state": "qc_passed", + "lc_x_qc__history": [ + { + "lc_state": "qc_passed", + "history_date": 1554120278 + }, + { + "lc_state": "reviewed", + "history_date": 1554120278 + }, + { + "lc_state": "reviewing", + "history_date": 1554120272 + }, + { + "lc_state": "checked", + "history_date": 1554120269 + }, + { + "lc_state": "checking", + "history_date": 1554120263 + }, + { + "lc_state": "arrived", + "history_date": 1554120252 + } + ], + "id": 70, + "truck__number_plate": "ZZZZZZ", + "user__pn": "15666666666" + }, + "result": 200 + }, + "context": null +} +``` + +## 装车单详情接口(3-1-1-1) + +### URL + +GET /adminsys/credential/lc/detail/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------ | -------- | +| id | Int | 装车单ID | +| user_sid | String | 会话 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| --------- | ---- | -------------- | +| details | List | 装车单详情信息 | +| aggregate | Dict | 总量 | + +### 请求例 + +获取 id=56 的装车单的详细信息 + +```http +GET /adminsys/credential/lc/detail/list/?id=56 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "aggregate": { + "aggregates": [ + { + "quantity": "50.000000", + "price": "50.000", + "unit": 2 + }, + { + "quantity": "96.420000", + "price": "96.420", + "unit": 1 + } + ], + "total_price": "146.420" + }, + "result": 200, + "details": [ + { + "price": "50.000", + "category__t_sub_name": "易拉罐", + "unit_price": "1", + "category__unit": 2, + "category__toptype_b__t_top_name": "易拉ddd", + "id": 112, + "quantity": "50.000000" + }, + { + "price": "22.000", + "category__t_sub_name": "测试123", + "unit_price": "1", + "category__unit": 1, + "category__toptype_b__t_top_name": "易拉ddd", + "id": 113, + "quantity": "22.000000" + }, + { + "price": "37.870", + "category__t_sub_name": "白料", + "unit_price": "1", + "category__unit": 1, + "category__toptype_b__t_top_name": "杂料(塑)", + "id": 114, + "quantity": "37.870000" + }, + { + "price": "10.000", + "category__t_sub_name": "其他杂料", + "unit_price": "1", + "category__unit": 1, + "category__toptype_b__t_top_name": "杂料(塑)", + "id": 115, + "quantity": "10.000000" + }, + { + "price": "1.000", + "category__t_sub_name": "红铜", + "unit_price": "1", + "category__unit": 1, + "category__toptype_b__t_top_name": "有色金属B", + "id": 116, + "quantity": "1.000000" + }, + { + "price": "21.000", + "category__t_sub_name": "黄铜", + "unit_price": "1", + "category__unit": 1, + "category__toptype_b__t_top_name": "有色金属B", + "id": 117, + "quantity": "21.000000" + }, + { + "price": "4.550", + "category__t_sub_name": "花料", + "unit_price": "1", + "category__unit": 1, + "category__toptype_b__t_top_name": "杂料(塑)", + "id": 118, + "quantity": "4.550000" + } + ] + }, + "context": null +} +``` + +### 一审和复审质检单详情(3-1-1-1) + +### URL + +GET /adminsys/credential/qc/detail/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------ | ---------- | +| id | Int | 装车单ID | +| qc_type | Alias | 质检单状态 | +| user_sid | String | 会话 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| --------- | ---- | ---------- | +| detail | Dict | 装车单详情 | +| aggregate | List | 总量 | + +### 注释 + +qc_tyoe 两种情况 + +| 值 | 含义 | +| ------ | ---------- | +| check | 第一次审查 | +| review | 复审 | + +### 请求例 + +获取 装车单id=70 的第一次审查的质检单详情 + +```http +GET /adminsys/credential/qc/detail/list/?id=70&qc_type=check +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "aggregate": { + "aggregates": [ + { + "quantity": "1111.000000", + "price": "1111.000", + "unit": 1 + } + ], + "total_price": "1111.000" + }, + "result": 200, + "details": [ + { + "price": "1111.000", + "unit_price": "1.000", + "category__name": "件铝", + "category__unit": 1, + "category__toptype__t_top_name": "有色金属B", + "id": 147, + "quantity": "1111.000000" + } + ] + }, + "context": null +} +``` + +## 邮件操作接口(3-1-1) + +### URL + +GET /adminsys/credential/lc/operate/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ------ | -------- | +| credential_type | Choice | 单子类型 | +| operate | Choice | 操作内容 | +| id | Int | 装车单id | +| user_sid | String | 会话 | + +### 应答 + +无 + +### 注释 + +credential_type + +| 值 | 含义 | +| ---- | ------ | +| load | 装车单 | +| qc | 质检单 | + +operate + +| 值 | 含义 | +| -------- | -------- | +| download | 下载汇总 | +| email | 发送邮件 | +| refresh | 刷新 | + +### 请求例 + +```http +GET /adminsys/credential/lc/operate/?credential_type=qc&operate=email&id=69 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} +``` + +### 注释 + +当进行下载时,会下载一个汇总表单 + +## 装车质检单下载接口(3-1-1) + +### URL + +GET /adminsys/credential/lc/download/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ----------------- | -------- | +| id_list | list | 装车单id | +| credential_type | Choice | 单子类型 | +| separated | Boolean(Optional) | 是否压缩 | +| user_sid | String | 会话 | + +### 应答 + +如果条件满足会直接下载 + +### 注释 + +credential + +| 值 | 含义 | +| ---- | ------ | +| qc | 质检单 | +| load | 装车单 | + +### 请求例 + +下载装车单ID为69的装车单,不打包 + +```http +GET /adminsys/credential/lc/download/?id_list=69&credential_type=load&separated=True +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} +``` + +会下载一个压缩包,解压之后就是需要的表单 + +## 获取装车单和质检单的汇总列表(3-1-2) + +### URL + +GET /adminsys/credential/lc/agg/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ------------------- | ---------------------- | +| agg_type | Choice | 按照什么方式汇总 | +| credential_type | Choice | 单子类型 | +| start_time | Timestamp(Optional) | 单子创建时间(用于过滤) | +| end_time | Timestamp(Optional) | 单子截至时间(用于过滤) | +| page | Int | 页码 | +| count_per_page | Int | 每页条目数 | +| user_sid | String | 会话 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ---------------------- | ---- | ------------ | +| credentials_aggregated | List | 单子汇总信息 | + +### 注释 + +agg_type + +| 值 | 含义 | +| ----- | -------- | +| day | 按天汇总 | +| week | 按周汇总 | +| month | 按月汇总 | + +credential_type + +| 值 | 含义 | +| ---- | ------ | +| qc | 质检单 | +| load | 装车单 | + +### 请求例 + +获取每周质检单的汇总列表,获取第二页,每页两条 + +```http +GET /adminsys/credential/lc/agg/list/?credential_type=qc&agg_type=week&page=1&count_per_page=2 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "n_pages": 2, + "credentials_aggregated": [ + { + "agg_type": "week", + "st_time": 1551621600, + "ed_time": 1552226400, + "price": "70.000" + }, + { + "agg_type": "week", + "st_time": 1549807200, + "ed_time": 1550412000, + "price": "1249.000" + } + ], + "result": 200 + }, + "context": null +} +``` + +### 装车单和质检单汇总的操作接口 (3-1-2) + +### URL + +GET /adminsys/credential/lc/agg/operate/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | --------- | --------------------- | +| operate | Choice | 操作内容 | +| st_time | Timestamp | 装车单/质检单开始时间 | +| agg_type | Choice | 汇总类型 | +| credential_type | Choice | 单子类型 | + +### 应答 + +如果时发邮件,会收到邮件信息 + +如果是下载,会下载对应的表单 + +### 注释 + +agg_type + +| 值 | 含义 | +| ----- | -------- | +| day | 按天汇总 | +| week | 按周汇总 | +| month | 按月汇总 | + + + +### 请求例 + +获取agg_type为week且st_time为1551621600的质检单,然后发邮件 + +```http +GET /adminsys/credential/lc/agg/operate/?credential_type=qc&operate=email&st_time=1551621600&agg_type=week +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} +``` + +### 获取装车单/质检单的邮件列表 + +### URL + diff --git a/docs/Reference/admin/login.md b/docs/Reference/admin/login.md index 81033b6..7740718 100644 --- a/docs/Reference/admin/login.md +++ b/docs/Reference/admin/login.md @@ -1,2 +1,43 @@ # 登录接口 +### URL + +GET /adminsys/login/login/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------ | -------- | +| username | String | 用户名 | +| password | String | 登陆密码 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| --------- | ------ | ----------------- | +| user_sid | String | session_key(会话) | +| user_info | DICT | 登录用户的信息 | + +### 请求例 + +```http +GET /adminsys/login/login/?username=wxroot&password=123456 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "user_sid": "35d0v4vm1v49z3wiwkiwakc29iys1s1e", + "user_info": { + "internal_name": "wxroot", + "pn": null + }, + "result": 200 + }, + "context": null +} +``` + diff --git a/docs/Reference/admin/recycle_bin/recycle_bin.md b/docs/Reference/admin/recycle_bin/recycle_bin.md new file mode 100644 index 0000000..8c0ebc4 --- /dev/null +++ b/docs/Reference/admin/recycle_bin/recycle_bin.md @@ -0,0 +1,344 @@ +# B端回收站点管理(4-2-1) + +## 获取回收站列表 + +### URL + +```http +GET /adminsys/recycle_bin/list/ +``` + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------------- | ----------- | ---------------------- | +| user_sid | String | 会话 | +| r_b_type | AliasChoice | 回收站类型(默认为None) | +| page | Int | 页码(过滤器) | +| count_per_page | Int | 每页条目数(过滤器) | +| extra_filter | String | 过滤条件(过滤器) | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ----------- | ---- | -------------------- | +| n_page | Int | 当前回收站列表总页数 | +| count_fix | Int | 固定站数量 | +| count_flow | Int | 流动站站数量 | +| count_all | Int | 回收站总数量 | +| recycle_bin | DICT | 回收站的详情 | + +### 请求例 + +```http +GET /adminsys/recycle_bin/list/ +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "n_pages": 10, + "count_fix": 18, + "count_flow": 10, + "result": 200, + "count_all": 28, + "recycle_bins": [ + { + "GPS_A": "52.2300000", + "in_use": true, + "GPS_L": "20.2491700", + "loc_desc": "测试回收站1", + "rb_name": "测试回收站1位于国金大厦11楼101", + "admins": [], + "r_b_type": "fix", + "position_desc": null, + "pn": "13472863621", + "id": 1 + }, + { + "GPS_A": "131.2391100", + "in_use": true, + "GPS_L": "121.5082800", + "loc_desc": "测试回收站2", + "rb_name": "测试回收站1位于国金大厦11楼102", + "admins": [], + "r_b_type": "fix", + "position_desc": null, + "pn": "13472863622", + "id": 2 + }, + { + "GPS_A": "38.9936400", + "in_use": true, + "GPS_L": "121.6614180", + "loc_desc": "测试回收站3", + "rb_name": "测试回收站1位于国金大厦11楼103", + "admins": [], + "r_b_type": "flow", + "position_desc": null, + "pn": "13472863623", + "id": 3 + } + ] + }, + "context": null +} +``` + +## 获取回收站的简化列表 + +### URL + +```http +GET /adminsys/recycle_bin/simplified/list/ +``` + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------------- | ----------- | ---------------------- | +| user_sid | String | 会话 | +| r_b_type | AliasChoice | 回收站类型(默认为None) | +| page | Int | 页码(过滤器) | +| count_per_page | Int | 每页条目数(过滤器) | +| extra_filter | String | 过滤条件(过滤器) | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ----------- | ---- | -------------------- | +| n_page | Int | 当前回收站列表总页数 | +| count_fix | Int | 固定站数量 | +| count_flow | Int | 流动站站数量 | +| count_all | Int | 回收站总数量 | +| recycle_bin | DICT | 回收站的详情 | + +### 请求例 + +```http +GET /adminsys/recycle_bin/simplified/list/ +``` + +### 应答例 + +```json +"n_pages": 3, + "count_fix": 18, + "count_flow": 10, + "result": 200, + "count_all": 28, + "recycle_bins": [ + { + "id": 1, + "rb_name": "测试回收站1位于国金大厦11楼101", + "r_b_type": "fix" + }, + { + "id": 2, + "rb_name": "测试回收站1位于国金大厦11楼102", + "r_b_type": "fix" + }, + { + "id": 3, + "rb_name": "测试回收站1位于国金大厦11楼103", + "r_b_type": "flow" + }, + { + "id": 4, + "rb_name": "测试站点1", + "r_b_type": "flow" + }, + { + "id": 5, + "rb_name": "华能联合大厦", + "r_b_type": "fix" + }, + { + "id": 6, + "rb_name": "陆家嘴正大广场", + "r_b_type": "fix" + }, + { + "id": 7, + "rb_name": "陆家嘴东方明珠电视塔", + "r_b_type": "fix" + }, + { + "id": 8, + "rb_name": "舒雅宾馆", + "r_b_type": "fix" + }, + { + "id": 9, + "rb_name": "测试地点1", + "r_b_type": "flow" + }, + { + "id": 10, + "rb_name": "测试地点2", + "r_b_type": "fix" + } + ] + }, + "context": null +} +``` + +## 回收站详情 + +### URL + +```http +GET /adminsys/recycle_bin/ +``` + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ---------- | +| id | Int | 回收站名称 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ----------- | ---- | -------------- | +| recycle_bin | DICT | 回收站详情信息 | + +### 请求例 + +```http +GET /adminsys/recycle_bin/?id=29 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "recycle_bin": { + "id": 29, + "GPS_L": null, + "GPS_A": null, + "rb_name": "天线宝宝回收", + "r_b_type": "flow", + "loc_desc": "保护环境,人人有责", + "position_desc": null, + "pn": "8008208821", + "in_use": true, + "admins": [], + "c_products": [], + "b_products": [] + }, + "result": 200 + }, + "context": null +} +``` + +--- + +### URL + +```http +POST /adminsys/recycle_bin/ +``` + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ------- | --------------------------- | +| default_product | Boolean | 是否使用默认商品(默认False) | +| recycle_bin | DICT | 要增加回收站的信息 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ---------------- | +| id | Int | 增加的回收站的ID | + +### 请求例 + +```http +POST /adminsys/recycle_bin/?user_sid=t4dzib2hcfimmksv3m6nuyu87u5g82jv +Host: - +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "recycle_bin":{ + "rb_name":"天线宝宝回收站", + "loc_desc":"保护环境,人人有责", + "r_b_type":"fix", + "pn":8008208821 + } + } +} +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200, + "id": 30 + }, + "context": null +} + +--- + +### URL + +```http +PUT /adminsys/recycle_bin/ +``` + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | -------------------- | +| id | Int | 要修改的回收站的ID | +| update | DICT | 要修改的回收站的信息 | + +### 应答 + +无 + +### 请求例 + +```http +PUT /adminsys/recycle_bin/?user_sid=t4dzib2hcfimmksv3m6nuyu87u5g82jv +Host: - +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "id":29, + "update":{ + "rb_name":"天线宝宝回收111", + "loc_desc":"保护环境,人人有责", + "r_b_type":"flow", + "pn":8008208821 + } + } +} +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +### 注释 + +修改接口的update内所有字段均为可选,更新方式为增量更新。 \ No newline at end of file diff --git a/docs/Reference/admin/user/achievement.md b/docs/Reference/admin/user/achievement.md new file mode 100644 index 0000000..cfe2ddc --- /dev/null +++ b/docs/Reference/admin/user/achievement.md @@ -0,0 +1,224 @@ +# 站长业绩相关接口(2-2) + +## 获取站长绩效列表(2-2-1) + +### URL + +GET /adminsys/achievement/achievement/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------------- | ------ | ---------- | +| user_sid | String | 会话 | +| page | Int | 页码 | +| count_per_page | Int | 每页条目数 | +| extra_filter | String | 过滤器 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| --------- | ---- | ------------ | +| referrers | List | 站长绩效信息 | + +### 请求例 + +获取所有站长的站长绩效列表 + +```http +GET /adminsys/achievement/achievement/list/?user_sid=8p2r7n015e8y2i1awjdsylmw89uuot4o +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "referrers": [ + { + "user__pn": "18513958704", + "total_promotion": "20.000", + "name": "樊1", + "count_orders": 1, + "user__internal_name": "18513958704", + "r_state": "pass", + "count_users": 0, + "id": 2, + "total_amount": "1000.000" + }, + { + "user__pn": "15900659180", + "total_promotion": "0.000", + "name": "weqweqw", + "count_orders": 0, + "user__internal_name": "oA8H64vA1QfwojWo3tlfEWJ1-AHg", + "r_state": "stop", + "count_users": 0, + "id": 3, + "total_amount": "0.000" + }, + { + "user__pn": "13261809966", + "total_promotion": "2.201", + "name": "崔玉珊", + "count_orders": 16, + "user__internal_name": "oA8H64q3DC_JDMlIwlrjasZBzwAk", + "r_state": "pass", + "count_users": 3, + "id": 4, + "total_amount": "220.100" + }, + { + "user__pn": "15652933853", + "total_promotion": "0.000", + "name": "吴敏", + "count_orders": 0, + "user__internal_name": "oA8H64nGBYdDPIaL4Er3JknqddmM", + "r_state": "pass", + "count_users": 0, + "id": 5, + "total_amount": "0.000" + }, + { + "user__pn": "15901712060", + "total_promotion": "0.000", + "name": "啊啊啊", + "count_orders": 0, + "user__internal_name": "oA8H64sErfLD9xcy7ysLPanPOeck", + "r_state": "pass", + "count_users": 0, + "id": 8, + "total_amount": "0.000" + }, + { + "user__pn": "18513958704", + "total_promotion": "0.000", + "name": "樊航宇", + "count_orders": 0, + "user__internal_name": "oA8H64tWjb8KaBBfQLiJs2c3eq38", + "r_state": "pass", + "count_users": 0, + "id": 9, + "total_amount": "0.000" + }, + { + "user__pn": "13232762061", + "total_promotion": "0.000", + "name": "朱老师", + "count_orders": 0, + "user__internal_name": "oA8H64mhneVpMCcwNIKngcZv5ObY", + "r_state": "pass", + "count_users": 1, + "id": 10, + "total_amount": "0.000" + }, + { + "user__pn": "17600484487", + "total_promotion": "0.000", + "name": "吴姬民", + "count_orders": 0, + "user__internal_name": "oA8H64qAYCM_1i4-wC-kD1FLBPBk", + "r_state": "pass", + "count_users": 0, + "id": 11, + "total_amount": "0.000" + }, + { + "user__pn": "15530106031", + "total_promotion": "0.000", + "name": "测试1", + "count_orders": 0, + "user__internal_name": "oA8H64sVm0IGhqX1pMkUeO80sKwI", + "r_state": "pass", + "count_users": 0, + "id": 12, + "total_amount": "0.000" + } + ], + "result": 200 + }, + "context": null +} +``` + +### 获取指定站长提成订单列表 + +### URL + +GET /adminsys/achievement/order/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ------------------- | ---------------------------------------- | +| id | Int | 站长ID | +| oeder_id | Int(Optional) | 订单ID | +| start_time | Timestamp(Optional) | 起始时间(过滤器) | +| end_time | Timestamp(Optional) | 截止时间(过滤器) | +| contact | String(Optional) | 联系人新姓名或电话(过滤器) | +| recycling_staff | String(Optional) | 回收人员(默认为None) | +| include_deleted | Boolean(Optional) | 是否包括已经删除的订单(过滤器,默认False) | +| r_b_type | Alias | 回收站类型 | +| dispatch_filter | Choice | 调度的过滤器 | +| page | Int(Optional) | 页码 | +| count_per_page | Int(Optional) | 每页条目数 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ------------------- | ---- | ------------------ | +| referrer | DICT | 站长信息 | +| count_flow | Int | 流动站订单数量 | +| count_fixed | Int | 固定站订单数量 | +| count_all | Int | 全部订单数量 | +| count_all_dispatch | Int | 被调度的订单数量 | +| count_need_dispatch | Int | 需要调度的订单数量 | +| n_page | Int | 页码数 | +| orders | List | 订单详情 | + +### 请求例 + +获取站长ID为2的站长订单详情 + +```http +GET /adminsys/achievement/order/list/?id=2 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "count_all_dispatch": 74, + "count_fixed": 44, + "referrer": { + "name": "樊1", + "r_state": "pass", + "id": 2, + "user__internal_name": "18513958704", + "user__pn": "18513958704" + }, + "count_need_dispatch": 2, + "n_pages": 1, + "count_flow": 212, + "result": 200, + "count_all": 324, + "orders": [ + { + "recycling_staff__rs_name": "Test", + "recycling_staff__rs_pn": "18627661345", + "o_state": "completed", + "budget": null, + "time_remain": 0, + "client": null, + "create_time": 1553652956, + "dispatch_state": "completed", + "id": 688 + } + ] + }, + "context": null +} +``` \ No newline at end of file diff --git a/docs/Reference/admin/user/order.md b/docs/Reference/admin/user/order.md new file mode 100644 index 0000000..e1420c4 --- /dev/null +++ b/docs/Reference/admin/user/order.md @@ -0,0 +1,319 @@ +# 订单相关接口(2-4) + +## 获取订单列表(2-4-1) + +### URL + +GET /adminsys/order/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ------------------- | ---------------------------------------- | +| oeder_id | Int(Optional) | 订单ID | +| start_time | Timestamp(Optional) | 起始时间(过滤器) | +| end_time | Timestamp(Optional) | 截止时间(过滤器) | +| contact | String(Optional) | 联系人新姓名或电话(过滤器) | +| recycling_staff | String(Optional) | 回收人员(默认为None) | +| include_deleted | Boolean(Optional) | 是否包括已经删除的订单(过滤器,默认False) | +| r_b_type | Alias | 回收站类型 | +| dispatch_filter | Choice | 调度的过滤器 | +| page | Int(Optional) | 页码(过滤器) | +| count_per_page | Int(Optional) | 每页条目数 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ------------------- | ---- | ------------------ | +| count_flow | Int | 流动站订单数量 | +| count_fixed | Int | 固定站订单数量 | +| count_all | Int | 全部订单数量 | +| count_all_dispatch | Int | 被调度的订单数量 | +| count_need_dispatch | Int | 需要调度的订单数量 | +| n_page | Int | 页码数 | +| orders | List | 订单详情 | + +### 注释 + +include_deleted + +| 值 | 含义 | +| ----- | ------ | +| True | 包括 | +| Flase | 不包括 | + +r_b_type + +| 值 | 含义 | +| ---- | ------ | +| fix | 固定站 | +| flow | 流动站 | + +dispatch_filter + +| 值 | 含义 | +| ------------- | -------- | +| need_dispatch | 需要调度 | +| all_dispatch | 全部调度 | + +### 请求例 + +获取订单ID为823的订单信息 + +```http +GET /adminsys/order/list/?order_id=823 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "count_all_dispatch": 87, + "count_fixed": 44, + "count_need_dispatch": 0, + "n_pages": 1, + "count_flow": 213, + "result": 200, + "count_all": 340, + "orders": [ + { + "recycling_staff__rs_name": "王五", + "recycling_staff__rs_pn": "18888888890", + "o_state": "deleted", + "budget": null, + "time_remain": 0, + "client": null, + "create_time": 1554342354, + "dispatch_state": "deleted", + "id": 823 + } + ] + }, + "context": null +} +``` + +## 获取订单详情接口 + +### URL + +GET /adminsys/order/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ------ | +| id | Int | 订单ID | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ---------------------- | +| order | DICT | 【扁平化】订单详情信息 | + +### 请求例 + +获取订单ID为823的订单详情 + +```http +GET /adminsys/order/?id=823 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "result": 200, + "order": { + "recycling_staff__rs_name": "王五", + "recycling_staff__rs_pn": "18888888890", + "o_state": "deleted", + "budget": null, + "time_remain": 0, + "client": null, + "create_time": 1554342354, + "customer_products": [], + "dispatch_state": "deleted", + "id": 823, + "history": [ + { + "loaded": false, + "o_state": "deleted", + "history_date": 1554364904 + }, + { + "loaded": false, + "o_state": "completed", + "history_date": 1554342354 + }, + { + "loaded": false, + "o_state": "pre_bookkeeping", + "history_date": 1554342354 + } + ] + } + }, + "context": null +} +``` + +**** + +### URL + +POST /adminsys/order/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ------ | ----------------- | +| products | List | 商品的信息(C端的) | +| order_type | Choice | 回收站类型 | +| c_delivery_info | DICT | 用户收获信息 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ------ | +| id | Int | 订单ID | + +### 注释 + +order_type + +| 值 | 含义 | +| ---- | ------------ | +| 0 | fix(固定站) | +| 1 | flow(流动站) | + +### 请求例 + +```http +POST /adminsys/order/?user_sid=gil5zpkfse06cu414wdwwwfggint8ksy +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "products":[], + "order_type":0, + "c_delivery_info":{ + "address":"北京市五道口", + "contact_pn":18888888890 + } + } +} +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200, + "id": 870 + }, + "context": null +} + +## 订单调度接口 + +### URL + +GET /adminsys/order/dispatch/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ---- | ------ | +| id | Int | 订单ID | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ------------- | ---- | -------- | +| dispatch_info | DICT | 调度信息 | + +### 请求例 + +获取订单ID为822的调度信息 + +```http +GET /adminsys/order/dispatch/?id=822&user_sid=v22qhig1oxxp8c12ww24lq8adzdpas15 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "dispatch_info": { + "dispatched_time": 1555419978, + "remark": "不错不错,味道好极了", + "id": 1, + "dispatcher__internal_name": "wxroot" + }, + "result": 200 + }, + "context": null +} +``` + +--- + +### URL + +POST /adminsys/order/dispatch/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| ------------- | ---- | -------- | +| id | Int | 订单ID | +| dispatch_info | DICT | 调度信息 | + +### 应答 + +无 + +### 请求例 + +```http +POST /adminsys/order/dispatch/?id=564&user_sid=8p2r7n015e8y2i1awjdsylmw89uuot4o +Host:- +Content-Type:application/json +cache-control:no=cache +{ + "data":{ + "id":564, + "dispatch_info":{ + "id":566, + "remark":"不错不错,味道好极了", + "order_id":566, + "dispatcher_id":3 + } + } +} + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +### 注释 + +在post时,必须保证order_dispatch_info__isnull=True才能添加成功,即订单的的状态不能有操作,在被创建的时候才能被调度。 + diff --git a/docs/Reference/admin/user/user_c.md b/docs/Reference/admin/user/user_c.md index 8dbb79e..b91b9e5 100644 --- a/docs/Reference/admin/user/user_c.md +++ b/docs/Reference/admin/user/user_c.md @@ -1,2 +1,79 @@ # C端用户后台管理接口 +## 获取C端用户信息列表 + +### URL + +后台 + +GET /adminsys/user/c/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ---------------- | ---------- | +| user_sid | String | 会话 | +| counte_per_page | Int(Optional) | 每页条目数 | +| page | Int(Optional) | 页码 | +| extra_filter | String(Optional) | 过滤器 | + +### 应答 + +| 字段名称 | 类型 | 含义 | +| -------------- | ---- | ------------------ | +| users | List | C端用户信息 | +| n_page | Int | 页码数 | +| count_active | Int | 正在使用的用户数量 | +| count_inactive | Int | 没有再用的用户数量 | +| count_all | Int | 总的用户数量 | + +### 请求例 + +获取C端用户,每页3个,取第1页 + +```http +GET /adminsys/user/c/list/?page=0&count_per_page=3 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "n_pages": 12, + "count_active": 34, + "result": 200, + "count_all": 34, + "users": [ + { + "openid": "oA8H64nGBYdDPIaL4Er3JknqddmM", + "user__pn": "15652933853", + "nickname": "oA8H64nGBYdDPIaL4Er3JknqddmM", + "user__is_active": true, + "user__last_login": 1555505026, + "user__user_validate": null + }, + { + "openid": "oA8H64kyiOeJA-tLefGf2f4IS8Pk", + "user__pn": "13472863621", + "nickname": "oA8H64kyiOeJA-tLefGf2f4IS8Pk", + "user__is_active": true, + "user__last_login": null, + "user__user_validate": null + }, + { + "openid": "oA8H64vqZyymJIw3LOmK5iwl9cyw", + "user__pn": null, + "nickname": "oA8H64vqZyymJIw3LOmK5iwl9cyw", + "user__is_active": true, + "user__last_login": null, + "user__user_validate": null + } + ], + "count_inactive": 0 + }, + "context": null +} +``` + diff --git a/docs/Reference/admin/user/user_qc.md b/docs/Reference/admin/user/user_qc.md index 9d1f7c0..be07b4d 100644 --- a/docs/Reference/admin/user/user_qc.md +++ b/docs/Reference/admin/user/user_qc.md @@ -1,2 +1,251 @@ # QC端用户后台管理接口 +# 获取列表 + +### URL + +后台 + +GET /adminsys/user/qc/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ---------------- | ---------- | +| user_id | String | 会话 | +| counte_per_page | Int(Optional) | 每页条目数 | +| page | Int(Optional) | 页码 | +| extra_filter | String(Optional) | 过滤器 | + +### 应答 + +| 字段名称 | 类型 | 含义 | +| -------------- | ------- | -------------------- | +| count_active | Int | 可用用户数量 | +| count_inactive | Int | 不可用用户数量 | +| count_all | Int | 全部用户数量 | +| qc_staffs | Flatten | 【扁平化】质检员列表 | + +### 请求例 + +获取用户名或手机号中包含"1"的质检员,每页3个,取第1页 + +```http +GET /adminsys/user/qc/list/?user_sid=pz23kuvify7z0brahp0ywne61iqinyf3&page=0&count_per_page=3&extra_filter=1 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "n_pages": 2, + "count_active": 6, + "qc_staffs": [ + { + "name": "fanhangyu", + "qc_role": "reviewer", + "user__is_active": true, + "qc_place__name": "测试场地2", + "qc_place__id": 1, + "join_date": 1548064560, + "id": 1, + "qc_place__loc_desc": "不知道aaa", + "user__pn": "18513958704" + }, + { + "name": "测试员1", + "qc_role": "reviewer", + "user__is_active": true, + "qc_place__name": "测试场地2", + "qc_place__id": 1, + "join_date": 1550032656, + "id": 2, + "qc_place__loc_desc": "不知道aaa", + "user__pn": "13888888888" + }, + { + "name": "测试员222", + "qc_role": "reviewer", + "user__is_active": true, + "qc_place__name": "测试场地2", + "qc_place__id": 1, + "join_date": 1550032674, + "id": 3, + "qc_place__loc_desc": "不知道aaa", + "user__pn": "13888888887" + } + ], + "result": 200, + "count_all": 6, + "count_inactive": 0 + }, + "context": null +} +``` + +# 获取详情 + +### URL + +后台 + +GET /adminsys/user/qc/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------ | -------- | +| user_id | String | 会话 | +| id | Int | 质检员ID | + +### 应答 + +| 字段名称 | 类型 | 含义 | +| -------- | ------- | -------------------- | +| qc_staff | Flatten | 【扁平化】质检员信息 | + +### 请求例 + +获取ID为1的已登录的质检员 + +```http +GET /adminsys/user/qc/?user_sid=pz23kuvify7z0brahp0ywne61iqinyf3&id=1 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "qc_staff": { + "name": "fanhangyu", + "qc_role": "reviewer", + "user__is_active": true, + "qc_place__name": "测试场地2", + "qc_place__id": 1, + "join_date": 1548064560, + "id": 1, + "qc_place__loc_desc": "不知道aaa", + "user__pn": "18513958704" + }, + "result": 200 + }, + "context": null +} +``` + +------ + +# 修改 + +### URL + +后台 + +PUT /adminsys/user/qc/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | --------------- | -------- | +| id | Int | 质检员ID | +| update | Partial Flatten | 质检员 | + +### 应答 + +无 + +### 请求例 + +```http +PUT /adminsys/user/qc/?user_sid=pz23kuvify7z0brahp0ywne61iqinyf3&id=1 +Host: - +Content-Type: application/json +cache-control: no-cache +Postman-Token: 7il3l1l3-zfgg-asom-aha0-8gxqf70kpo1c +{ + "data":{ + "id":1, + "update":{ + "name":"fanhangyu", + "qc_role": "reviewer", + "user__is_active": true, + "qc_place__name": "测试场地3", + "qc_place_id": 1, + "id":1, + "join_date": 1548064560, + "qc_place__loc_desc": "不知道ddd", + "user__pn": "18513958704" + } + } +} + +``` + +### 注释 + +修改接口的update内所有字段均为可选,更新方式为增量更新。 + +例如,update下不含user_pn,则不对质检员手机号进行更新。 + +------ + +# 新增 + +### URL + +后台 + +POST /adminsys/user/qc/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------- | ---------- | +| qc_staff | Flatten | 质检员视图 | + +### 应答 + +| 字段名称 | 类型 | 含义 | +| -------- | ---- | -------- | +| id | Int | 质检员ID | + +### 请求例 + +```http +POST /adminsys/user/qc/?user_sid=pz23kuvify7z0brahp0ywne61iqinyf3 +Host: - +Content-Type: application/json +cache-control: no-cache +Postman-Token: 7il3l1l3-zfgg-asom-aha0-8gxqf70kpo1c +{ + "data":{ + "qc_staff":{ + "name":"fanhangyu", + "qc_role": "reviewer", + "user__is_active": true, + "qc_place__name": "测试场地2", + "qc_place_id": 1, + "id":1, + "join_date": 1548064560, + "qc_place__loc_desc": "不知道ddd", + "user__pn": "18513958705" + } + } +} +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200, + "id": 7 + }, + "context": null +} + diff --git a/docs/Reference/admin/user/user_r.md b/docs/Reference/admin/user/user_r.md index c93a5fd..131a02a 100644 --- a/docs/Reference/admin/user/user_r.md +++ b/docs/Reference/admin/user/user_r.md @@ -1,2 +1,236 @@ # 站长后台管理接口 +# 获取列表 + +### URL + +后台 + +GET /adminsys/user/r/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------------- | ---------------- | ---------- | +| user_sid | String | 会话 | +| count_per_page | Int(Optional) | 每页条目数 | +| page | Int(Optional) | 页码 | +| extra_filter | String(Optional) | 过滤器 | + +### 应答 + +| 字段名称 | 类型 | 含义 | +| -------------- | ---- | -------------------- | +| count_active | Int | 可用用户数量 | +| count_inactive | Int | 不可用用户数量 | +| count_all | Int | 全部用户数量 | +| referrers | List | 【扁平化】推荐人列表 | + +### 请求例 + +获取用户名或手机号中包含'1'的站长,每页3个,取第1页 + +```http +GET /adminsys/user/r/list/?user_sid=user_sid_admin&count_per_page=3&page=0&extra_filter=1 + +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "n_pages": 4, + "count_active": 10, + "result": 200, + "count_all": 10, + "referrers": [ + { + "name": "樊1", + "referrer_code": "aba5a6f5dba0432aaf245b62335651d0", + "r_state": "pass", + "expire_date": 1548946500, + "operator": null, + "position": null, + "percentage": "0.0000", + "pass_date": null, + "id": 2, + "user__pn": "18513958704" + }, + { + "name": "weqweqw", + "referrer_code": "8e3d249bddcb42ffa6a415f7ba1fe99e", + "r_state": "pass", + "expire_date": 1551323820, + "operator": null, + "position": null, + "percentage": "0.0000", + "pass_date": null, + "id": 3, + "user__pn": "15900659180" + }, + { + "name": "崔玉珊", + "referrer_code": "47af18026c6b4d30bfabdfc33c227cd6", + "r_state": "pass", + "expire_date": 1864723920, + "operator": null, + "position": null, + "percentage": "0.0100", + "pass_date": null, + "id": 4, + "user__pn": "13261809966" + } + ], + "count_inactive": 0 + }, + "context": null +} +``` + +# 获取详情 + +### URL + +后台 + +GET /adminsys/user/r/qr/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------ | -------- | +| user_sid | String | 会话 | +| id | Int | 推荐人ID | + +### 应答 + +| 字段名称 | 类型 | 含义 | +| -------- | ----- | ------------ | +| qr_bin | image | 推荐人二维码 | + +### 请求列 + +获取用户名或用户手机号中推荐人ID为3的推荐人二维码 + +```http +GET /adminsys/user/r/qr/?user_sid=user_id_admin&id=3 +``` + +### 应答例 + +无 + +# 获取详情 + +### URL + +后台 + +GET /adminsys/user/r/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------ | -------- | +| user_id | String | 会话 | +| id | Int | 推荐人ID | + +### 应答 + +| 字段名称 | 类型 | 含义 | +| -------- | ---- | ---------- | +| referrer | Dict | 推荐人信息 | + +### 请求例 + +获取推荐人ID为3的推荐人信息 + +```http +GET /adminsys/user/r/?user_sid=pz23kuvify7z0brahp0ywne61iqinyf3&id=3 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "referrer": { + "name": "weqweqw", + "referrer_code": "8e3d249bddcb42ffa6a415f7ba1fe99e", + "r_state": "pass", + "expire_date": 1551323899, + "operator": null, + "position": "3", + "percentage": "0.0000", + "pass_date": null, + "id": 3, + "user__pn": "15900659180" + }, + "result": 200 + }, + "context": null +} +``` + +------ + +# 修改 + +### URL + +后台 + +PUT /adminsys/user/r/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | --------------- | ---------- | +| id | Int | 推荐人ID | +| update | Partial Flatten | 推荐人视图 | + +### 应答 + +无 + +### 请求例 + +```http +PUT /adminsys/user/r/?user_sid=pz23kuvify7z0brahp0ywne61iqinyf3&id=3 +Host: - +Content-Type: application/json +cache-control: no-cache +Postman-Token: 7il3l1l3zf-ggas-omah-a08g-xqf70kpo1c +{ + "data":{ + "id":3, + "update":{ + "name":"weqweqw", + "percentage":"0.0000", + "expire_date":1551323899, + "r_state":"pass", + "position":"3", + "operator":"1" + } + } +} +``` + +### 应答例 + +表示更新成功 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +### 注释 + +修改接口的update内所有字段均为可选,更新方式为增量更新。 diff --git a/docs/Reference/admin/user/validate.md b/docs/Reference/admin/user/validate.md new file mode 100644 index 0000000..f739997 --- /dev/null +++ b/docs/Reference/admin/user/validate.md @@ -0,0 +1,227 @@ +# 用户校验相关的接口 + +## 获取用户认证详情 + +### URL + +GET /adminsys/validate/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ------ | ------ | +| user_sid | String | 会话 | +| id | Int | 用户ID | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ------------- | ---- | ------------------ | +| user_validate | DICT | 【扁平化】用户信息 | + +### 请求例 + +获取用户id为1 的用户信息 + +```http +GET /adminsys/validate/?id=1 +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "user_validate": { + "name": "孙悟空", + "idcard_number": "22222222222222", + "user__internal_name": "oA8H64ugV3Tr_dXgBhN77PeTwlI4", + "validate_status": "accepted", + "uid": 7, + "id": 1, + "user__pn": "13717611792" + }, + "result": 200 + }, + "context": null +} +``` + +## 审核通过/拒绝用户的接口 + +### URL + +POST /adminsys/validate/operate/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ------ | ---------- | +| user_sid | String | 会话 | +| id | Int | 用户ID | +| validate_status | Alias | 校验的状态 | + +### 应答 + +wu + +### 注释 + +validate_status + +| 值 | 含义 | +| -------- | ------------------------------------ | +| accepted | 用户已提交认证审核申请,且审核已通过 | +| rejected | 用户已提交认证审核申请,审核被拒绝 | + +### 请求例 + +```http +POST /adminsys/validate/operate/ HTTP/1.1 +Host: - +Content-Type: applicate/json +Postman-Token:hkwm3819jtkx6tqqc8unyfaeeb20ji8j +{ + "data":{ + "id":1, + "validate_status":"rejected" + } +} + +``` + +### 应答例 + +{ + "version": "2.0", + "response": { + "result": 200 + }, + "context": null +} + +## 获取用户认证列表 + +### URL + +GET /adminsys/validate/list/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| --------------- | ------------------- | ---------- | +| user_sid | String | 会话 | +| validate_status | Alias(Optional) | 校验的状态 | +| submit_date | Timestamp(Optional) | 提交时间 | +| page | Int(Optional) | 页码 | +| count_per_page | Int(Optional) | 每页条目数 | +| extra_filter | String(Optional) | 过滤器 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| ------------------- | ---- | ---------------------- | +| count_all | Int | 总人数 | +| count_need_validate | Int | 需要验证的人数 | +| user_validate | List | 验证通过的用户信息列表 | +| n_pages | Int | 页码数 | + +### 注释 + +validate_status + +| 值 | 含义 | +| -------- | ---------- | +| accepted | 审核通过 | +| rejected | 审核被拒绝 | + +### 请求例 + +获取用户认证列表中状态为rejected的用户信息 + +```http +GET /adminsys/validate/list/?validate_status=rejected +``` + +### 应答例 + +```json +{ + "version": "2.0", + "response": { + "n_pages": 1, + "count_all": 1, + "result": 200, + "count_need_validate": 0, + "user_validates": [ + { + "passed_date": 1555347835, + "name": "孙悟空", + "submit_date": null, + "idcard_number": "22222222222222", + "user__internal_name": "oA8H64ugV3Tr_dXgBhN77PeTwlI4", + "validate_status": "rejected", + "uid": 7, + "id": 1, + "user__pn": "13717611792" + } + ] + }, + "context": null +} +``` + +## 获取用户认证照片 + +### URL + +GET /adminsys/validate/photo/ + +### 请求参数 + +| 参数名称 | 类型 | 含义 | +| -------- | ----- | -------- | +| user_sid | Int | 会话 | +| id | Int | 用户ID | +| t_photo | Alias | 照片类型 | + +### 应答 + +| 参数名称 | 类型 | 含义 | +| -------------------- | ---------- | ------------------- | +| FileResponse | image | 验证通过的用户照片 | +| HttpResponseNotFound | text/plain | 抛异常,photo不存在 | + +### 注释 + +t_photo + +| 值 | 含义 | +| ------- | -------------- | +| handled | 手持证件的照片 | +| top | 身份证正面照 | +| bottom | 身份证反面照 | + + + +如果存在,就返回用户验证通过的照片 + +否则,会提示用户photo不存在 + +### 请求例 + +获取用户ID为1的用户,手持身份证的照片 + +```http +GET /adminsys/validate/photo/?id=1&t_photo=handled +``` + +### 应答例 + +暂无数据 + +如果没有数据,应答如下 + +Photo does not exist +