You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
40 lines
933 B
40 lines
933 B
import { defHttp } from '@/utils/http/axios' |
|
|
|
export type task = { |
|
id: string |
|
name: string |
|
} |
|
export type ProcessInstanceVO = { |
|
id: number |
|
name: string |
|
processDefinitionId: string |
|
category: string |
|
result: number |
|
tasks: task[] |
|
fields: string[] |
|
status: number |
|
remark: string |
|
businessKey: string |
|
createTime: string |
|
endTime: string |
|
} |
|
|
|
export function getMyProcessInstancePage(params) { |
|
return defHttp.get({ url: '/bpm/process-instance/my-page', params }) |
|
} |
|
|
|
export function createProcessInstance(data: ProcessInstanceVO) { |
|
return defHttp.post({ url: '/bpm/process-instance/create', data }) |
|
} |
|
|
|
export function cancelProcessInstance(id: number, reason: string) { |
|
const data = { |
|
id: id, |
|
reason: reason |
|
} |
|
return defHttp.delete({ url: '/bpm/process-instance/cancel', data }) |
|
} |
|
|
|
export function getProcessInstance(id: number) { |
|
return defHttp.get({ url: '/bpm/process-instance/get?id=' + id }) |
|
}
|
|
|