hangzhoumesParent/common/servicebase/src/main/java/com/mes/common/config/Const.java
@@ -28,7 +28,7 @@ * 卧式理片笼详情表玻璃状态 * 识别后成功状态100 * 出片任务101 * 人工下片101 * 人工下片102 * 拿走200 * 破损201 */ @@ -150,5 +150,11 @@ public static final List<Integer> G11_WORK_STATION = Arrays.asList(4, 5, 6); public static final List<Integer> G13_WORK_STATION = Arrays.asList(7); /** * 启用 1 * 禁用 0 */ public static final Integer SLOT_ON = 1; public static final Integer SLOT_OFF = 0; } hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstorage/service/impl/BigStorageCageDetailsServiceImpl.java
@@ -229,6 +229,7 @@ MPJLambdaWrapper<BigStorageCage> wrapper = new MPJLambdaWrapper<>(BigStorageCage.class) .selectAll(BigStorageCage.class) .leftJoin(BigStorageCageDetails.class, BigStorageCageDetails::getSlot, BigStorageCage::getSlot) .eq(BigStorageCage::getEnableState, Const.SLOT_ON) .eq(BigStorageCageDetails::getTemperingLayoutId, glassInfo.getTemperingLayoutId()) .gt(BigStorageCage::getRemainWidth, glassInfo.getWidth()) .last("limit 1"); @@ -245,6 +246,7 @@ return bigStorageDTO; } bigStorageCage = bigStorageCageService.getOne(new LambdaQueryWrapper<BigStorageCage>() .eq(BigStorageCage::getEnableState, Const.SLOT_ON) .eq(BigStorageCage::getRemainWidth, slotWidth) .inSql(BigStorageCage::getDeviceId, "select distinct device_id from big_storage_cage_details where tempering_layout_id = " + glassInfo.getTemperingLayoutId()) @@ -257,6 +259,7 @@ } bigStorageCage = bigStorageCageService.getOne(new LambdaQueryWrapper<BigStorageCage>() .eq(BigStorageCage::getRemainWidth, slotWidth) .eq(BigStorageCage::getEnableState, Const.SLOT_ON) .last("limit 1")); Assert.isTrue(null != bigStorageCage, "没有空余的笼子存放玻璃"); bigStorageDTO = new BigStorageDTO(); hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstoragetask/mapper/BigStorageCageFeedTaskMapper.java
@@ -1,9 +1,8 @@ package com.mes.bigstoragetask.mapper; import com.baomidou.dynamic.datasource.annotation.DS; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.mes.bigstorage.entity.BigStorageDTO; import com.github.yulichang.base.MPJBaseMapper; import com.mes.bigstorage.entity.BigStorageDTO; import com.mes.bigstoragetask.entity.BigStorageCageFeedTask; import org.apache.ibatis.annotations.Param; @@ -17,7 +16,7 @@ * @author zhoush * @since 2024-04-16 */ @DS("salve_hangzhoumes") @DS("salve_hangzhoumes_1") public interface BigStorageCageFeedTaskMapper extends MPJBaseMapper<BigStorageCageFeedTask> { List<Integer> querySitToUpGlass(); hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstoragetask/mapper/BigStorageCageOutTaskMapper.java
@@ -15,7 +15,7 @@ * @author zhoush * @since 2024-04-16 */ @DS("salve_hangzhoumes") @DS("salve_hangzhoumes_1") public interface BigStorageCageOutTaskMapper extends BaseMapper<BigStorageCageOutTask> { boolean saveBatch(@Param(value = "list") List<BigStorageCageOutTask> list); hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/edgstoragetask/controller/TaskCacheController.java
File was deleted hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/edgstoragetask/entity/TaskCache.java
File was deleted hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/edgstoragetask/mapper/TaskCacheMapper.java
File was deleted hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/edgstoragetask/service/TaskCacheService.java
File was deleted hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/edgstoragetask/service/impl/TaskCacheServiceImpl.java
File was deleted hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/job/PlcStorageCageTask.java
@@ -72,8 +72,11 @@ @Value("${mes.slotWidth}") private Integer slotWidth; @Value("${mes.carMaxSize}") private Integer carMaxSize; @Value("${mes.inCarMaxSize}") private Integer inCarMaxSize; @Value("${mes.outCarMaxSize}") private Integer outCarMaxSize; @Value("${mes.galssGap}") private Integer galssGap; @@ -309,7 +312,7 @@ Integer widthSecond = edgGlassTaskInfoList.get(1).getWidth(); if (remainWidth >= widthFirst) { if (remainWidth - widthFirst - galssGap >= widthSecond) { if (glassCount <= carMaxSize - 1) { if (glassCount <= inCarMaxSize - 1) { addFeedTask(glassId, line, Const.BIG_STORAGE_IN_WAIT, widthFirst); } else { addFeedTask(glassId, line, Const.BIG_STORAGE_IN_RUN, widthFirst); @@ -433,7 +436,7 @@ //打车剩余尺寸 Integer remainWidth = carWidth; for (T e : list) { if (bigStorageCageOutTaskList.size() > carMaxSize || e.getWidth() > remainWidth) { if (bigStorageCageOutTaskList.size() > outCarMaxSize || e.getWidth() > remainWidth) { break; } remainWidth = remainWidth - (int) e.getWidth() - galssGap; hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/application-cz.yml
@@ -14,6 +14,10 @@ username: sa password: beibo.123/ driver-class-name: com.microsoft.sqlserver.jdbc.SQLServerDriver salve_hangzhoumes_1: url: jdbc:sqlserver://192.168.20.2:1433;databasename=hangzhoumes username: sa password: beibo.123/ cloud: nacos: discovery: hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/application.yml
@@ -16,5 +16,6 @@ minCount: 5 carWidth: 5000 #大车宽度 slotWidth: 5000 #大车宽度 carMaxSize: 6 #大车最大存放玻璃数量 galssGap: 20 #玻璃间距 inCarMaxSize: 6 #进片大车最大存放玻璃数量 outCarMaxSize: 1 #出片大车最大存放玻璃数量 galssGap: 300 #玻璃间距 hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/mapper/BigStorageCageDetailsMapper.xml
@@ -37,7 +37,7 @@ ) T2 INNER JOIN (SELECT ENGINEER_ID, TEMPERING_LAYOUT_ID, COUNT(TEMPERING_FEED_SEQUENCE) AS COUNT FROM BIG_STORAGE_CAGE_DETAILS WHERE STATE = 100 WHERE STATE in (100, 101, 102) GROUP BY ENGINEER_ID, TEMPERING_LAYOUT_ID) T3 ON T2.ENGINEER_ID = T3.ENGINEER_ID AND T2.TEMPERING_LAYOUT_ID = T3.TEMPERING_LAYOUT_ID AND T2.COUNT = T3.COUNT LIMIT 1 hangzhoumesParent/moduleService/UnLoadGlassModule/src/main/java/com/mes/AppRunnerConfig.java
@@ -1,6 +1,6 @@ package com.mes; //import com.mes.common.S7object; import com.mes.common.S7object; import lombok.extern.slf4j.Slf4j; import org.springframework.boot.ApplicationArguments; @@ -14,7 +14,6 @@ @Slf4j @Component @Order(1) public class AppRunnerConfig implements ApplicationRunner { @@ -22,6 +21,5 @@ public void run(ApplicationArguments args) throws Exception { log.info("启动完成"); S7object.getinstance().start(); } }