提交 620b7e4d 编写于 作者: sq3536's avatar sq3536

避免重复提交

上级 1aed7567
......@@ -142,7 +142,11 @@ public class WFCoreService
throw new BadRequestAlertException("未找到对应的工作流配置",entity,businessKey);
processDefinitionKey=definitionKeys.get(0);
}
String processInstanceBusinessKey=system+":"+entity+":k-"+businessKey;
if(runtimeService.createProcessInstanceQuery().processDefinitionKey(processDefinitionKey).processInstanceBusinessKey(processInstanceBusinessKey).count()>0)
throw new BadRequestAlertException("已经启动过流程,不能重复提交",entity,businessKey);
Map<String, Object> variables = new LinkedHashMap<>();
variables.put("businessKey",businessKey);
variables.put("activedata",instance.get("activedata"));
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册