Skip to content

Commit b09ff41

Browse files
committed
feat: 同步bpm设计器审批人配置,发起人部门负责人,发起人连续多级部门的负责人
1 parent 6b39710 commit b09ff41

File tree

1 file changed

+17
-3
lines changed
  • src/components/bpmnProcessDesigner/package/penal/task/task-components

1 file changed

+17
-3
lines changed

src/components/bpmnProcessDesigner/package/penal/task/task-components/UserTask.vue

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<template>
2-
<el-form label-width="100px">
2+
<el-form label-width="120px">
33
<el-form-item label="规则类型" prop="candidateStrategy">
44
<el-select
55
v-model="userTaskForm.candidateStrategy"
@@ -111,7 +111,7 @@
111111
</el-form-item>
112112
<el-form-item
113113
v-if="userTaskForm.candidateStrategy === CandidateStrategy.FORM_USER"
114-
label="用户字段"
114+
label="表单内用户字段"
115115
prop="formUser"
116116
>
117117
<el-select
@@ -140,7 +140,7 @@
140140
prop="deptLevel"
141141
span="24"
142142
>
143-
<el-select v-model="deptLevel" clearable>
143+
<el-select v-model="deptLevel" clearable @change="updateElementTask">
144144
<el-option
145145
v-for="(item, index) in MULTI_LEVEL_DEPT"
146146
:key="index"
@@ -258,6 +258,12 @@ const resetTaskForm = () => {
258258
return num > Number.MAX_SAFE_INTEGER || num < -Number.MAX_SAFE_INTEGER ? item : num
259259
})
260260
deptLevel.value = +candidateParamStr.split('|')[1]
261+
} else if (
262+
userTaskForm.value.candidateStrategy == CandidateStrategy.START_USER_DEPT_LEADER ||
263+
userTaskForm.value.candidateStrategy == CandidateStrategy.START_USER_MULTI_LEVEL_DEPT_LEADER
264+
) {
265+
userTaskForm.value.candidateParam = +candidateParamStr
266+
deptLevel.value = +candidateParamStr
261267
} else {
262268
userTaskForm.value.candidateParam = candidateParamStr.split(',').map((item) => {
263269
// 如果数字超出了最大安全整数范围,则将其作为字符串处理
@@ -319,6 +325,14 @@ const updateElementTask = () => {
319325
if (userTaskForm.value.candidateStrategy == CandidateStrategy.MULTI_LEVEL_DEPT_LEADER) {
320326
candidateParam += '|' + deptLevel.value
321327
}
328+
// 特殊处理发起人部门负责人、发起人连续部门负责人
329+
if (
330+
userTaskForm.value.candidateStrategy == CandidateStrategy.START_USER_DEPT_LEADER ||
331+
userTaskForm.value.candidateStrategy == CandidateStrategy.START_USER_MULTI_LEVEL_DEPT_LEADER
332+
) {
333+
candidateParam = deptLevel.value + ''
334+
}
335+
322336
const extensions = bpmnInstances().moddle.create('bpmn:ExtensionElements', {
323337
values: [
324338
...otherExtensions.value,

0 commit comments

Comments
 (0)