update - 兼容测试老模型数据的问题
This commit is contained in:
parent
8d4dd259c8
commit
635c81107b
@ -4,6 +4,8 @@ import cn.axzo.workflow.core.service.support.forecast.impl.SequenceFlowForecasti
|
||||
import cn.axzo.workflow.core.service.support.spring.FlowableConditionEvaluatorAware;
|
||||
import org.flowable.bpmn.model.FlowElement;
|
||||
import org.flowable.engine.runtime.ProcessInstance;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
|
||||
import java.util.ArrayList;
|
||||
@ -24,6 +26,7 @@ import static cn.axzo.workflow.core.service.support.FlowNodeForecastService.FORE
|
||||
public abstract class AbstractForecast<T extends FlowElement> implements Forecast<T>, FlowableConditionEvaluatorAware {
|
||||
|
||||
private FlowableConditionEvaluator conditionEvaluator;
|
||||
private static final Logger log = LoggerFactory.getLogger(AbstractForecast.class);
|
||||
|
||||
@Override
|
||||
public final List<FlowElement> nextFlowElement(FlowElement sourceFlowElement, ProcessInstance instance) {
|
||||
@ -85,6 +88,11 @@ public abstract class AbstractForecast<T extends FlowElement> implements Forecas
|
||||
* @see SequenceFlowForecasting#calcRealOutgoingNodes(List, ProcessInstance) 参考这里的用法
|
||||
*/
|
||||
protected final Boolean conditionOn(String exp, String processInstanceId) {
|
||||
return conditionEvaluator.conditionOn(exp, processInstanceId);
|
||||
try {
|
||||
return conditionEvaluator.conditionOn(exp, processInstanceId);
|
||||
} catch (Exception e) {
|
||||
log.warn("条件评估发生异常: {}", e.getMessage());
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user