| Version | Update Time | Status | Author | Description |
|---|---|---|---|---|
0.0.1 | 2023-03-06 17:25:00 | 创建文档 | 浮生 | 初始化接口文档 |
1. 报备模块
1.1. 信息上传
Type: POST
Author: 27951
Content-Type: application/json; charset=utf-8
Description: 信息上传
Body-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
name | string | 姓名 | true | - |
phone | string | 手机号 | true | - |
wxPhone | string | 微信绑定手机号 | false | - |
company | string | 单位名称 | true | - |
content | string | 事件登记 | true | - |
Request-example:
curl -X POST -H 'Content-Type: application/json; charset=utf-8' -i http://localhost:8888/reporting/informationReporting/add --data '{
"name": "博文.秦",
"phone": "15275670227",
"wxPhone": "15275670227",
"company": "彭, 薛 and 金",
"content": "hjimvz"
}'Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
Response-example:
{
"success": true,
"message": "success",
"code": "57751",
"data": "fkc5al"
}1.2. 删除信息
Type: DELETE
Author: 27951
Content-Type: application/json; charset=utf-8
Description: 删除信息
Request-headers:
| Header | Type | Description | Required | Since |
|---|---|---|---|---|
admin_token | string | null | true | - |
Body-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
id | int64 | 调用者id(管理员 上传信息的人) | false | - |
name | string | 调用者姓名(管理员 上传信息的人) | false | - |
ids | array | id数组 | false | - |
Request-example:
curl -X DELETE -H 'Content-Type: application/json; charset=utf-8' -H 'admin_token' -i http://localhost:8888/reporting/informationReporting/delete --data '{
"id": 138,
"name": "博文.秦",
"ids": [
59
]
}'Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
Response-example:
{
"success": true,
"message": "success",
"code": "57751",
"data": "o2s5as"
}1.3. 项目列表
Type: GET
Author: 27951
Content-Type: application/x-www-form-urlencoded;charset=utf-8
Description: 项目列表
Request-headers:
| Header | Type | Description | Required | Since |
|---|---|---|---|---|
admin_token | string | null | true | - |
Query-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
name | string | 姓名 | false | - |
phone | string | 电话号码 | false | - |
company | string | 单位名称 | false | - |
reportingTime | string | 创建时间 | false | - |
currPage | int32 | 当前页,默认1 | false | - |
pageSize | int32 | 每页大小,默认10 | false | - |
orderField | string | 排序字段,可选择值参考返回结果 | false | - |
order | string | 排序方式,可选值:asc、desc | false | - |
Request-example:
curl -X GET -H 'admin_token' -i http://localhost:8888/reporting/informationReporting/list?order=jjc6zj&pageSize=10&name=博文.秦&phone=15275670227&reportingTime=2023-03-14 18:45:03&company=彭, 薛 and 金&orderField=kadzdd&currPage=1Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
└─totalCount | int32 | 总记录数 | - |
└─pageSize | int32 | 每页记录数 | - |
└─totalPage | int32 | 总页数 | - |
└─currPage | int32 | 当前页数 | - |
└─list | array | 列表数据 | - |
└─id | int64 | id | - |
└─userName | string | 用户名 | - |
└─name | string | 管理员姓名 | - |
└─password | string | 密码 | - |
└─adminType | int32 | 角色类别 1超级管理员、2管理员 | - |
└─time | string | 创建时间 | - |
└─status | int32 | 状态(0停用 1正常) | - |
Response-example:
{
"success": true,
"message": "success",
"code": "57751",
"data": {
"totalCount": 965,
"pageSize": 10,
"totalPage": 1,
"currPage": 1,
"list": [
{
"id": 437,
"userName": "博文.秦",
"name": "博文.秦",
"password": "wca319",
"adminType": 780,
"time": "2023-03-14 18:45:03",
"status": 759
}
]
}
}1.4. 信息导出
Type: GET
Author: 27951
Content-Type: application/x-www-form-urlencoded;charset=utf-8
Description: 信息导出
Query-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
ids | array | id数组 | false | - |
name | string | 姓名 | false | - |
phone | string | 电话号码 | false | - |
company | string | 所在公司 | false | - |
reportingTime | string | 创建时间 | false | - |
Request-example:
curl -X GET -i http://localhost:8888/reporting/informationReporting/download?name=博文.秦&phone=15275670227&reportingTime=2023-03-14 18:45:03&ids=ylils5&ids=ylils5&company=彭, 薛 and 金Response-example:
Doesn't return a value.2. 账户管理模块
2.1. 管理员登录
Type: POST
Content-Type: application/json; charset=utf-8
Description: 管理员登录
Body-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
userName | string | 用户名 | true | - |
password | string | 密码 | true | - |
Request-example:
curl -X POST -H 'Content-Type: application/json; charset=utf-8' -i http://localhost:8888/reporting/user/login --data '{
"userName": "博文.秦",
"password": "c9e6q9"
}'Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
└─id | int64 | id | - |
└─userName | string | 用户名 | - |
└─name | string | 管理员姓名 | - |
└─password | string | 密码 | - |
└─adminType | int32 | 角色类别 1超级管理员、2管理员 | - |
└─time | string | 创建时间 | - |
└─status | int32 | 状态(0停用 1正常) | - |
Response-example:
{
"success": true,
"message": "success",
"code": "57751",
"data": {
"id": 656,
"userName": "博文.秦",
"name": "博文.秦",
"password": "rkv8bc",
"adminType": 890,
"time": "2023-03-14 18:45:03",
"status": 470
}
}2.2. 添加管理员
Type: POST
Content-Type: application/json; charset=utf-8
Description: 添加管理员
Request-headers:
| Header | Type | Description | Required | Since |
|---|---|---|---|---|
admin_token | string | null | true | - |
Body-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
id | int64 | id | false | - |
userName | string | 用户名 | true | - |
name | string | 管理员姓名 | true | - |
password | string | 密码 | true | - |
Request-example:
curl -X POST -H 'Content-Type: application/json; charset=utf-8' -H 'admin_token' -i http://localhost:8888/reporting/user/add --data '{
"id": 582,
"userName": "博文.秦",
"name": "博文.秦",
"password": "uyjpb8"
}'Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
Response-example:
{
"success": true,
"message": "success",
"code": "57751",
"data": "zx6v0d"
}2.3. 删除管理员
Type: DELETE
Content-Type: application/json; charset=utf-8
Description: 删除管理员
Request-headers:
| Header | Type | Description | Required | Since |
|---|---|---|---|---|
admin_token | string | null | true | - |
Body-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
ids | array | id数组 | false | - |
Request-example:
curl -X DELETE -H 'Content-Type: application/json; charset=utf-8' -H 'admin_token' -i http://localhost:8888/reporting/user/delete --data '{
"ids": [
587
]
}'Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
Response-example:
{
"success": true,
"message": "success",
"code": "57751",
"data": "cojhhf"
}2.4. 修改管理员信息
Type: PUT
Content-Type: application/json; charset=utf-8
Description: 修改管理员信息
Request-headers:
| Header | Type | Description | Required | Since |
|---|---|---|---|---|
admin_token | string | null | true | - |
Body-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
id | int64 | id | false | - |
userName | string | 用户名 | true | - |
name | string | 管理员姓名 | true | - |
password | string | 密码 | true | - |
Request-example:
curl -X PUT -H 'Content-Type: application/json; charset=utf-8' -H 'admin_token' -i http://localhost:8888/reporting/user/update --data '{
"id": 855,
"userName": "博文.秦",
"name": "博文.秦",
"password": "k6mwa7"
}'Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
Response-example:
{
"success": true,
"message": "success",
"code": "57751",
"data": "suqrk4"
}2.5. 修改本人密码
Type: PUT
Content-Type: application/json; charset=utf-8
Description: 修改本人密码
Request-headers:
| Header | Type | Description | Required | Since |
|---|---|---|---|---|
admin_token | string | null | true | - |
Body-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
id | int64 | 当前登录管理员id | true | - |
password | string | 原密码,密码使用公钥加密后传输 | true | - |
newPassword | string | 新密码,密码使用公钥加密后传输 | true | - |
Request-example:
curl -X PUT -H 'Content-Type: application/json; charset=utf-8' -H 'admin_token' -i http://localhost:8888/reporting/user/updatePassword --data '{
"id": 871,
"password": "7fwznb",
"newPassword": "uklrjd"
}'Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
Response-example:
{
"success": true,
"message": "success",
"code": "57751",
"data": "ahs5ny"
}2.6. 管理员列表
Type: GET
Content-Type: application/x-www-form-urlencoded;charset=utf-8
Description: 管理员列表
Request-headers:
| Header | Type | Description | Required | Since |
|---|---|---|---|---|
admin_token | string | null | true | - |
Query-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
userName | string | 用户名 | false | - |
name | string | 管理员姓名 | false | - |
time | string | 创建时间 | false | - |
currPage | int32 | 当前页,默认1 | false | - |
pageSize | int32 | 每页大小,默认10 | false | - |
orderField | string | 排序字段,可选择值参考返回结果 | false | - |
order | string | 排序方式,可选值:asc、desc | false | - |
Request-example:
curl -X GET -H 'admin_token' -i http://localhost:8888/reporting/user/list?pageSize=10&orderField=s2b1hp&userName=博文.秦&time=2023-03-14 18:45:03&order=02icqp&name=博文.秦&currPage=1Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
└─totalCount | int32 | 总记录数 | - |
└─pageSize | int32 | 每页记录数 | - |
└─totalPage | int32 | 总页数 | - |
└─currPage | int32 | 当前页数 | - |
└─list | array | 列表数据 | - |
└─id | int64 | id | - |
└─userName | string | 用户名 | - |
└─name | string | 管理员姓名 | - |
└─password | string | 密码 | - |
└─adminType | int32 | 角色类别 1超级管理员、2管理员 | - |
└─time | string | 创建时间 | - |
└─status | int32 | 状态(0停用 1正常) | - |
Response-example:
{
"success": true,
"message": "success",
"code": "57751",
"data": {
"totalCount": 915,
"pageSize": 10,
"totalPage": 1,
"currPage": 1,
"list": [
{
"id": 791,
"userName": "博文.秦",
"name": "博文.秦",
"password": "v802jp",
"adminType": 353,
"time": "2023-03-14 18:45:04",
"status": 133
}
]
}
}3. 获取微信绑定手机号
3.1. 通过code换取用户手机号
Type: GET
Content-Type: application/x-www-form-urlencoded;charset=utf-8
Description: 通过code换取用户手机号
Query-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
code | string | No comments found. | false | - |
state | string | No comments found. | false | - |
Request-example:
curl -X GET -i http://localhost:8888/reporting/wx/getPhone?state=96s8ui&code=57751Response-example:
string