Commit 26c728b050e5e7dcc8032aba4b4313da75f69e44

Authored by SuperHao
Committed by Gitee
1 parent 3cee922e

bugfix: 当修改保存模型,再发布时,提示"流程定义部署失败,原因:信息未发生变化"

yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/service/definition/BpmProcessDefinitionServiceImpl.java
@@ -199,8 +199,8 @@ public class BpmProcessDefinitionServiceImpl implements BpmProcessDefinitionServ @@ -199,8 +199,8 @@ public class BpmProcessDefinitionServiceImpl implements BpmProcessDefinitionServ
199 // 校验 BPMN XML 信息 199 // 校验 BPMN XML 信息
200 BpmnModel newModel = buildBpmnModel(createReqDTO.getBpmnBytes()); 200 BpmnModel newModel = buildBpmnModel(createReqDTO.getBpmnBytes());
201 BpmnModel oldModel = getBpmnModel(oldProcessDefinition.getId()); 201 BpmnModel oldModel = getBpmnModel(oldProcessDefinition.getId());
202 - // TODO 貌似 flowable 不修改这个也不同。需要看看。 sourceSystemId 不同  
203 - if (FlowableUtils.equals(oldModel, newModel)) { 202 + // 对比字节变化
  203 + if (!FlowableUtils.equals(oldModel, newModel)) {
204 return false; 204 return false;
205 } 205 }
206 // 最终发现都一致,则返回 true 206 // 最终发现都一致,则返回 true