fix: 修复流程分支节点预测问题

This commit is contained in:
lizhixian 2025-02-17 09:52:09 +08:00
parent 045a224c22
commit 3d20ce1a9b
1 changed files with 2 additions and 1 deletions

View File

@ -780,7 +780,8 @@ public class BpmnModelUtils {
Gateway gateway = (Gateway) currentElement;
SequenceFlow matchSequenceFlow = CollUtil.findOne(gateway.getOutgoingFlows(),
flow -> ObjUtil.notEqual(gateway.getDefaultFlow(), flow.getId())
&& evalConditionExpress(variables, flow.getConditionExpression()));
//流程第一次发起时variables条件值一定为空发生异常会导致后续分支节点无法预测
|| (null != variables && evalConditionExpress(variables, flow.getConditionExpression())));
if (matchSequenceFlow == null) {
matchSequenceFlow = CollUtil.findOne(gateway.getOutgoingFlows(),
flow -> ObjUtil.equal(gateway.getDefaultFlow(), flow.getId()));