主题
申请统计
用于查询系统中的申请统计数据;
接口说明
请求URL:http[s]://{网关地址}/casp-tdc/processInstance/count
请求方式: POST
请求内容类型: application/json
响应内容类型: application/json
请求说明
请求体
| 字段名 | 参数名 | 必填 | 类型 | 描述 |
|---|---|---|---|---|
| 用户工号 | userId | O | String(50) | 用户工号 |
| 开始时间 | startTime | O | String | 开始时间(yyyy-MM-dd HH:mm:ss) |
| 结束时间 | endTime | O | String | 结束时间(yyyy-MM-dd HH:mm:ss) |
请求示例
json
{
"userId":"test-gh",
"startTime":"2020-01-01 12:00:00",
"endTime":"2020-01-01 12:00:00"
}1
2
3
4
5
2
3
4
5
响应说明
响应体
| 字段名 | 参数名 | 类型 | 描述 |
|---|---|---|---|
| 返回码 | errcode | String | 返回码 |
| 返回描述 | errmsg | String | 返回描述 |
| 申请总数 | total | integer | 申请总数 |
| 进行中申请总数量 | doingCount | integer | 进行中申请总数量 |
| 正常结束申请总数量 | finishCount | integer | 正常结束申请总数量 |
| 草稿状态申请总数量 | draftCount | integer | 草稿状态申请总数量 |
响应示例
json
{
"errcode": "0",
"errmsg": "success",
"traceId": null,
"total": 0,
"doingCount": 0,
"finishCount": 0
}1
2
3
4
5
6
7
8
2
3
4
5
6
7
8
错误码
| 错误码 | 描述 |
|---|---|
| 376999 | 系统异常,详细描述信息参见接口返回 |
| 999 | 统一错误码,详细描述信息参见接口返回 |
Demo
java
// 创建客户端
Client client = new DefaultClient(BASE_URL, APP_ID, APP_SECRET);
// 创建请求对象
ProcessInstanceCountRequest request = new ProcessInstanceCountRequest();
request.setUserId("xxx");
ProcessInstanceCountResponse response = client.execute(request);
//调用成功,则处理业务逻辑
if (response.isSuccess()) {
//.....
}1
2
3
4
5
6
7
8
9
10
2
3
4
5
6
7
8
9
10

