|
|
|
|
@ -1,4 +1,4 @@ |
|
|
|
|
import { getFormByProcessId, startProcess, detail, completeTask, transferTask, delegateTask, rollbackTask, terminateProcess, addMultiInstance } from '@/api/plugin/workflow/process' |
|
|
|
|
import { getFormByProcessId, startProcess, detail, completeTask, transferTask, delegateTask, rollbackTask, terminateProcess, addMultiInstance, withdrawTask } from '@/api/plugin/workflow/process' |
|
|
|
|
|
|
|
|
|
import Layout from '@/page/index/' |
|
|
|
|
import defaultValues from './default-values' |
|
|
|
|
@ -277,6 +277,28 @@ export default { |
|
|
|
|
} |
|
|
|
|
this.$refs['user-select'].visible = false |
|
|
|
|
}, |
|
|
|
|
handleWithdrawTask() { |
|
|
|
|
const { taskId } = this.process |
|
|
|
|
this.$confirm('<p><span style="color: red;">撤销:</span>撤销终止此流程</p><p><span style="color: red;">撤回:</span>撤回到发起人重新提交,若当前流程不存在发起人节点,功能同撤销</p>', '请选择撤销/撤回操作', { |
|
|
|
|
type: 'warning', |
|
|
|
|
distinguishCancelAndClose: true, |
|
|
|
|
confirmButtonText: '撤销', |
|
|
|
|
cancelButtonText: '撤回', |
|
|
|
|
dangerouslyUseHTMLString: true |
|
|
|
|
}).then(() => { |
|
|
|
|
withdrawTask({taskId, withdrawType: 'wf_withdraw_end'}).then(() => { |
|
|
|
|
this.$message.success("操作成功") |
|
|
|
|
this.handleCloseTag('/plugin/workflow/process/todo') |
|
|
|
|
}) |
|
|
|
|
}).catch((action) => { |
|
|
|
|
if (action == 'cancel') { |
|
|
|
|
withdrawTask({taskId, withdrawType: 'wf_withdraw_start'}).then(() => { |
|
|
|
|
this.$message.success("操作成功") |
|
|
|
|
this.handleCloseTag('/plugin/workflow/process/todo') |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
}, |
|
|
|
|
handlePrint() { // 打印
|
|
|
|
|
// const watermarkText = this.userInfo.user_name + " " + this.userInfo.dept_name
|
|
|
|
|
// Watermark.set({ watermark_txt: watermarkText }) // 添加水印
|
|
|
|
|
@ -336,6 +358,10 @@ export default { |
|
|
|
|
comment = '减签:' + fullMessage |
|
|
|
|
ff.class = 'nodeError' |
|
|
|
|
} |
|
|
|
|
if (type == 'withdrawComment') { |
|
|
|
|
comment = '撤销:' + fullMessage |
|
|
|
|
ff.class = 'nodeWarn' |
|
|
|
|
} |
|
|
|
|
if (type == 'comment') { |
|
|
|
|
comment = '审批:' + fullMessage |
|
|
|
|
ff.class = 'nodeSuccess' |
|
|
|
|
|