yangys
2025-09-13 3ffe33aaa24386337e3638558eca731c62f25521
blade-service/blade-mdm/src/main/java/org/springblade/mdm/flow/excution/StartDispatcher.java
@@ -21,7 +21,6 @@
import org.springblade.mdm.program.service.ProgramSeqService;
import org.springblade.mdm.utils.EntityUtil;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.flowable.engine.RuntimeService;
import org.springframework.transaction.annotation.Transactional;
@@ -90,14 +89,14 @@
      if(StringUtils.isNotBlank(startVO.getDeviation())) {
         vars.put(FlowContants.DEVIATION, startVO.getDeviation());//偏离单
      }
      String programPkgName = NcNodeService.genProgramName(startVO.getDrawingNo(),startVO.getProcessNo());
      String programPkgName = NcNodeService.genProgramName(startVO.getDrawingNo(),startVO.getProcessNo(),startVO.getProcessEdition());
      vars.put(FlowContants.PROGRAM_PACKAGE_NAME,programPkgName);
      vars.put(FlowContants.IS_TEMP_FLOW,FlowContants.Y.equals(startVO.getIsTempFlow())?FlowContants.Y:FlowContants.N);
      NcNode curedProgramPackage = null;
      if(!startVO.isTemporaryFlow() && !startVO.isDeviationFlow()) {
         //正常流程(非临时流程) 且不是 偏离单,才匹配固化程序
         curedProgramPackage = ncNodeService.getLastCuredProgramPackageWithoutProcessEdition(programPkgName,startVO.getMachineCode());
         curedProgramPackage = ncNodeService.getLastCuredProgramWithoutProcessEdition(startVO.getDrawingNo(),startVO.getProcessNo(),startVO.getMachineCode());
         //设置是否有固化程序标记
         vars.put(FlowContants.HAS_CURED_PROGRAM, curedProgramPackage != null ? FlowContants.Y : FlowContants.N);
         //工序版次是否一致,是否在有效期内