| | |
| | | import request from '@/config/axios' |
| | | |
| | | export type TaskVO = { |
| | | id: number |
| | | /** |
| | | * 任务状态枚举 |
| | | */ |
| | | export enum TaskStatusEnum { |
| | | /** |
| | | * 未开始 |
| | | */ |
| | | NOT_START = -1, |
| | | |
| | | /** |
| | | * 待审批 |
| | | */ |
| | | WAIT = 0, |
| | | /** |
| | | * 审批中 |
| | | */ |
| | | RUNNING = 1, |
| | | /** |
| | | * 审批通过 |
| | | */ |
| | | APPROVE = 2, |
| | | |
| | | /** |
| | | * 审批不通过 |
| | | */ |
| | | REJECT = 3, |
| | | |
| | | /** |
| | | * 已取消 |
| | | */ |
| | | CANCEL = 4, |
| | | /** |
| | | * 已退回 |
| | | */ |
| | | RETURN = 5, |
| | | /** |
| | | * 审批通过中 |
| | | */ |
| | | APPROVING = 7 |
| | | } |
| | | |
| | | export const getTaskTodoPage = async (params: any) => { |
| | |
| | | }) |
| | | } |
| | | |
| | | // 获取所有可回退的节点 |
| | | // 获取所有可退回的节点 |
| | | export const getTaskListByReturn = async (id: string) => { |
| | | return await request.get({ url: '/bpm/task/list-by-return', params: { id } }) |
| | | } |
| | | |
| | | // 回退 |
| | | // 退回 |
| | | export const returnTask = async (data: any) => { |
| | | return await request.put({ url: '/bpm/task/return', data }) |
| | | } |
| | |
| | | return await request.delete({ url: '/bpm/task/delete-sign', data }) |
| | | } |
| | | |
| | | // 抄送 |
| | | export const copyTask = async (data: any) => { |
| | | return await request.put({ url: '/bpm/task/copy', data }) |
| | | } |
| | | |
| | | // 获取我的待办任务 |
| | | export const myTodoTask = async (processInstanceId: string) => { |
| | | return await request.get({ url: '/bpm/task/my-todo?processInstanceId=' + processInstanceId }) |
| | | } |
| | | |
| | | // 获取减签任务列表 |
| | | export const getChildrenTaskList = async (id: string) => { |
| | | return await request.get({ url: '/bpm/task/list-by-parent-task-id?parentTaskId=' + id }) |