野心家
2023-05-31 d209d7621ff92670e5157ae7f19162d097114678
src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
@@ -131,7 +131,7 @@
//                // 入出库模式判断
//                if ( inSta.getStaNo()==180 && devpThread.ioMode != IoModeType.PAKIN_MODE) { continue; }
                staProtocol.setPakMk(true);
                // 判断是否满足入库条件
                if (staProtocol.isAutoing() && staProtocol.isLoading()
                        && staProtocol.isInEnable()
@@ -165,7 +165,11 @@
//                    }
                    try {
                        String pack=barcode.substring(6);//pack码
                        String pack =null;//pack码
                        if(barcode.length()>6){
                            pack=barcode.substring(6);
                    }
                        //String pack="MJY0136 0400";
                        barcode=barcode.substring(0,6);//托盘码
                        LocTypeDto locTypeDto = new LocTypeDto(staProtocol);
                        locTypeDto.setLocType1((short)1);
@@ -184,7 +188,6 @@
                        JSONObject jsonObject = JSON.parseObject(response);
                        if (jsonObject.getInteger("code").equals(200)) {
                            StartupDto dto = jsonObject.getObject("data", StartupDto.class);
                            barcodeThread.setBarcode("");
                            staProtocol.setWorkNo(dto.getWorkNo().shortValue());
                            staProtocol.setStaNo(dto.getStaNo().shortValue());
@@ -750,7 +753,7 @@
            crnCommand.setDestinationPosX(locMast.getRow1().shortValue());     // 目标库位排
            crnCommand.setDestinationPosY(locMast.getBay1().shortValue());     // 目标库位列
            crnCommand.setDestinationPosZ(locMast.getLev1().shortValue());     // 目标库位层\
            crnCommand.setBarcode(wrkMast.getBarcode());
            crnCommand.setBarcode(wrkMast.getBarcode());//托盘码
            if (!MessageQueue.offer(SlaveType.Crn, wrkMast.getCrnNo(), new Task(2, crnCommand))) {
                log.error("堆垛机命令下发失败,堆垛机号={},任务数据={}", wrkMast.getCrnNo(), JSON.toJSON(crnCommand));
            } else {
@@ -1082,6 +1085,7 @@
        crnCommand.setDestinationPosX(sta.getRow1().shortValue());     // 目标库位排
        crnCommand.setDestinationPosY(sta.getBay1().shortValue());     // 目标库位列
        crnCommand.setDestinationPosZ(sta.getLev1().shortValue());     // 目标库位层
        crnCommand.setBarcode(wrkMast.getBarcode());//托盘码
        if (!MessageQueue.offer(SlaveType.Crn, wrkMast.getCrnNo(), new Task(2, crnCommand))) {
            log.error("堆垛机命令下发失败,堆垛机号={},任务数据={}", wrkMast.getCrnNo(), JSON.toJSON(crnCommand));
        } else {