♻️ Refactoring code. 优化流程变量为空处理逻辑

This commit is contained in:
lbw committed 2023-08-01 15:52:23 +08:00
1 parent 014a372c5c
commit 71749e7234
2 files changed
+4 -4

No files matched your search

@@ -70,7 +70,7 @@ public class ExpressionHandler {
long valueTime = DateUtil.parse(value.toString(), format).getTime();
long paramTime = DateUtil.parse(param.toString(), format).getTime();
return compare(StrUtil.format("${key{}{}}", symbol, paramTime), Dict.create().set("key", valueTime));
return compare(StrUtil.format("key{}{}", symbol, paramTime), Dict.create().set("key", valueTime));
}
/**
@@ -90,7 +90,7 @@ public class ExpressionHandler {
return false;
}
return compare(StrUtil.format("${key{}{}}", symbol, param), Dict.create().set("key", Convert.toNumber(value)));
return compare(StrUtil.format("key{}{}", symbol, param), Dict.create().set("key", Convert.toNumber(value)));
}
@@ -127,7 +127,7 @@ public class ExpressionHandler {
log.debug("参数值:{} 格式化显示:{}", paramDateTime.getTime(), DateUtil.formatDateTime(paramDateTime));
// 获取模板
return compare(StrUtil.format("${key{}{}}", symbol, paramDateTime.getTime()),
return compare(StrUtil.format("key{}{}", symbol, paramDateTime.getTime()),
Dict.create().set("key", valueDateTime.getTime()));
}
@@ -568,7 +568,7 @@ public class ModelUtil {
{
SequenceFlow sequenceFlow = buildSingleSequenceFlow(gatewayId, endId,
StrUtil.format("${!" + "{}_approve_condition}", nodeId));
StrUtil.format("${!var:get({}_approve_condition)}", nodeId));
sequenceFlowList.add(sequenceFlow);
}