Skip to content

Commit 88bbbec

Browse files
author
cuicui20210817
committed
回退-任务
1 parent d6ebaf8 commit 88bbbec

File tree

2 files changed

+17
-2
lines changed

2 files changed

+17
-2
lines changed

src/api/bpm/task.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,13 @@ export function rejectTask(data) {
3939
data: data
4040
})
4141
}
42+
export function backTask(data) {
43+
return request({
44+
url: '/bpm/task/back',
45+
method: 'PUT',
46+
data: data
47+
})
48+
}
4249

4350
export function updateTaskAssignee(data) {
4451
return request({

src/views/bpm/processInstance/detail.vue

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ import store from "@/store";
109109
import {decodeFields} from "@/utils/formGenerator";
110110
import Parser from '@/components/parser/Parser'
111111
import {createProcessInstance, getProcessInstance} from "@/api/bpm/processInstance";
112-
import {approveTask, getTaskListByProcessInstanceId, rejectTask, updateTaskAssignee} from "@/api/bpm/task";
112+
import {approveTask, getTaskListByProcessInstanceId, rejectTask, updateTaskAssignee,backTask} from "@/api/bpm/task";
113113
import {getDate} from "@/utils/dateUtils";
114114
import {listSimpleUsers} from "@/api/system/user";
115115
import {getActivityList} from "@/api/bpm/activity";
@@ -406,7 +406,15 @@ export default {
406406
},
407407
/** 处理审批退回的操作 */
408408
handleBack(task) {
409-
this.$modal.msgError("暂不支持【退回】功能!");
409+
const data = {
410+
id: task.id,
411+
assigneeUserId: 1
412+
}
413+
// this.$modal.msgError("暂不支持【--退回】功能!");
414+
backTask(data).then(response => {
415+
this.$modal.msgSuccess("回退成功!");
416+
this.getDetail(); // 获得最新详情
417+
});
410418
}
411419
}
412420
};

0 commit comments

Comments
 (0)