File tree Expand file tree Collapse file tree 1 file changed +12
-11
lines changed
src/components/bpmnProcessDesigner/package/designer Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Original file line number Diff line number Diff line change @@ -120,20 +120,21 @@ export default {
120
120
this .bpmnModeler .getDefinitions ().rootElements [0 ].flowElements ? .forEach (n => {
121
121
let activity = activityList .find (m => m .key === n .id ) // 找到对应的活动
122
122
if (n .$type === ' bpmn:UserTask' ) { // 用户任务
123
- debugger
124
123
if (! activity) {
125
124
return ;
126
125
}
127
126
// 处理用户任务的高亮
128
127
const task = this .taskList .find (m => m .id === activity .taskId ); // 找到活动对应的 taskId
129
- if (task) {
130
- canvas .addMarker (n .id , this .getResultCss (task .result ));
131
- // 如果非通过,就不走后面的线条了
132
- if (task .result !== 2 ) {
133
- return ;
134
- }
128
+ if (! task) {
129
+ return ;
135
130
}
131
+ // 高亮任务
132
+ canvas .addMarker (n .id , this .getResultCss (task .result ));
136
133
134
+ // 如果非通过,就不走后面的线条了
135
+ if (task .result !== 2 ) {
136
+ return ;
137
+ }
137
138
// 处理 outgoing 出线
138
139
const outgoing = this .getActivityOutgoing (activity);
139
140
outgoing? .forEach (nn => {
@@ -219,13 +220,13 @@ export default {
219
220
return activity .endTime ? ' highlight' : ' highlight-todo' ;
220
221
},
221
222
getResultCss (result ) {
222
- if (result === 1 ) {
223
+ if (result === 1 ) { // 审批中
223
224
return ' highlight-todo' ;
224
- } else if (result === 2 ) {
225
+ } else if (result === 2 ) { // 已通过
225
226
return ' highlight' ;
226
- } else if (result === 3 ) {
227
+ } else if (result === 3 ) { // 不通过
227
228
return ' highlight-reject' ;
228
- } else if (result === 4 ) {
229
+ } else if (result === 4 ) { // 已取消
229
230
return ' highlight-cancel' ;
230
231
}
231
232
return ' ' ;
You can’t perform that action at this time.
0 commit comments