0fe2b07e3e2be31e43dd859057f0e6781397e2c4..913818442a98ee3c2b26bec9904d3d5925806b11
2025-06-25 Junjie
#
913818 对比 | 目录
2025-06-25 Junjie
#
8e3aef 对比 | 目录
2025-06-25 Junjie
#
8e233c 对比 | 目录
2025-06-25 ytfl
#
fab191 对比 | 目录
2个文件已修改
33 ■■■■■ 已修改文件
src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java 32 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/zy/common/constant/RedisConstantType.java 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
@@ -2206,13 +2206,16 @@
        ArrayList<Integer> list = new ArrayList<Integer>(){{add(2003);add(2002);}};
        for (Integer staNo : list) {
            Integer devpId = null;
            Integer rgvStaNoDevpId = null;
            Integer rgvStaNo = null;
            if (staNo == 2003) {
                devpId = 1;
                rgvStaNo = 2002;
                rgvStaNoDevpId = 2;
            }else {
                devpId = 2;
                rgvStaNo = 2003;
                rgvStaNoDevpId = 1;
            }
            SiemensDevpThread devpThread = (SiemensDevpThread) SlaveConnection.get(SlaveType.Devp, devpId);
@@ -2228,7 +2231,7 @@
            if (staProtocol.isAutoing()
                    && staProtocol.isLoading()
//                    && staProtocol.isInEnable()
                    && staProtocol.isInEnable()
                    && staProtocol.getWorkNo() > 0
            ) {
                WrkMast wrkMast = wrkMastService.selectOne(new EntityWrapper<WrkMast>()
@@ -2239,6 +2242,28 @@
                }
                if (wrkMast.getWrkSts() == 201) {
                    continue;
                }
                SiemensDevpThread devpThread2 = (SiemensDevpThread) SlaveConnection.get(SlaveType.Devp, rgvStaNoDevpId);
                if (devpThread2 == null) {
                    continue;
                }
                StaProtocol staProtocolRgvStaNo = devpThread2.getStation().get(rgvStaNo);
                if (staProtocolRgvStaNo == null) {
                    continue;
                }
                if (!staProtocolRgvStaNo.isAutoing()) {
                    continue;
                }
                if (staProtocolRgvStaNo.isLoading()) {
                    continue;
                }
                Object object = redisUtil.get(RedisConstantType.RGV_MOVE_LOCK + wrkMast.getWrkNo());
                if (object != null) {
                    continue;
                }
@@ -2259,6 +2284,7 @@
                wrkMast.setWrkSts(201L);//201.RGV搬运中
                wrkMast.setModiTime(new Date());
                wrkMastService.updateById(wrkMast);
                redisUtil.set(RedisConstantType.RGV_MOVE_LOCK + wrkMast.getWrkNo(), "lock", 60 * 60);
            }
        }
    }
@@ -2287,6 +2313,10 @@
                    continue;
                }
                if (wrkMast.getWrkSts() != 201) {
                    continue;
                }
                Integer devpId = null;
                Integer devpStaNo = null;
                String locNo = null;
src/main/java/com/zy/common/constant/RedisConstantType.java
@@ -3,5 +3,6 @@
public class RedisConstantType {
    public static final String CRN_MOVE_LOCK = "CRN_MOVE_LOCK_";
    public static final String RGV_MOVE_LOCK = "RGV_MOVE_LOCK_";
}