瀏覽代碼

aps-调度排程挪动数据修改

sucheng 2 月之前
父節點
當前提交
75fd45b541

+ 2 - 2
cx-aps/cx-aps-common/src/main/java/com/rongwei/bscommon/sys/service/impl/ApsBlankOrderServiceImpl.java

@@ -4434,8 +4434,8 @@ public class ApsBlankOrderServiceImpl extends ServiceImpl<ApsBlankOrderDao, ApsB
                     .eq(ApsProcessOperationProcessEquDo::getTenantid, tenantId));
             List<String> unLockingEquIdList2 = unLockingEquList2.stream().map(ApsProcessOperationProcessEquDo::getId).collect(Collectors.toList());
 
-            //将实际完工时间大于明天的作业挪到实际完工时间
-            this.baseMapper.updateFinishDateAboutProcessEqu(needScheduleDate, tenantId, chongpaiStartDate, chongpaiEndDate);
+//            //将实际完工时间大于明天的作业挪到实际完工时间
+//            this.baseMapper.updateFinishDateAboutProcessEqu(needScheduleDate, tenantId, chongpaiStartDate, chongpaiEndDate);
 //            int safeCount2 = 0;
 //            while (true) {
 //                int updateCount2 = this.baseMapper.moveErrorProcessEqu2(chongpaiStartDate, chongpaiEndDate, CXCommonUtils.getCurrentUserFactoryId(currentUser));

+ 0 - 16
cx-aps/cx-aps-common/src/main/resources/mybatis/ApsBlankOrderDao.xml

@@ -219,22 +219,6 @@
           and apope.PLANENDDATE > #{needScheduleDate} -- 计划完工时间大于调度开始时间,即占用了调度时间
           and apo.PROCESS != '铸轧'
           and apope.TENANTID = #{tenantId};
-        update
-        aps_process_operation_process_equ apope
-        join aps_process_operation apo on apo.ID = apope.PROCESSID
-        left join aps_process_operation_process_equ preapope on apope.PREVIOUSPROCESSESIDS = preapope.id AND preapope.DELETED = '0'
-        set
-        apope.PLANSTARTDATE=DATE_SUB(date_add(preapope.PLANENDDATE, INTERVAL ifnull(apo.MAXFLOWWAITMIN,0) MINUTE),INTERVAL TIMESTAMPdiff(SECOND, apope.PLANSTARTDATE, apope.PLANENDDATE) SECOND),
-        apope.PLANENDDATE=date_add(preapope.PLANENDDATE, INTERVAL ifnull(apo.MAXFLOWWAITMIN,0) MINUTE)
-        WHERE
-        apope.deleted = '0' AND apo.DELETED = '0'
-        and apope.TENANTID = #{tenantId}
-        and apo.PROCESS != '铸轧'
-        and apope.WORKSTATUS = '待开工'
-        and apope.PLANSTARTDATE between #{chongpaiStartDate} and #{chongpaiEndDate}  -- 占用调度时间范围内
-        and ifnull(apo.MAXFLOWWAITMIN,0) > 0 -- 有最大流转等待时间
-        AND ifnull(apope.PREVIOUSPROCESSESIDS,'') != '' -- 有前道
-        and date_add(preapope.PLANENDDATE, INTERVAL ifnull(apo.MAXFLOWWAITMIN,0) MINUTE) &lt; #{chongpaiStartDate} -- 前道完工时间+最大流转时间小于调度开始时间
     </update>
     <update id="removeLockNextDayProcessEqu">
         with tomorroworder as(