| | |
| | | log.info("errmsg: " + errMsg); |
| | | // News.warn("扫码入库失败,{}入库站因{}异常,托盘已被退回", inSta.getStaNo(), errMsg); |
| | | MessageQueue.offer(SlaveType.Led, inSta.getLed(), new Task(3, errMsg)); |
| | | |
| | | if (!staProtocol.isLoading()) { |
| | | continue; |
| | | } |
| | |
| | | } |
| | | |
| | | |
| | | // 获取条码扫描仪信息 |
| | | //BarcodeThread barcodeThread = (BarcodeThread) SlaveConnection.get(SlaveType.Barcode, inSta.getBarcode()); |
| | | if (barcodeThread == null) { |
| | | continue; |
| | | } |
| | | // 获取入库站信息 |
| | | //SiemensDevpThread devpThread = (SiemensDevpThread) SlaveConnection.get(SlaveType.Devp, devp.getId()); |
| | | //StaProtocol staProtocol = devpThread.getStation().get(inSta.getStaNo()); |
| | | if (staProtocol == null) { |
| | | continue; |
| | | } else { |
| | | staProtocol = staProtocol.clone(); |
| | | } |
| | | |
| | | |
| | | //LED |
| | | //LedThread ledThread = (LedThread) SlaveConnection.get(SlaveType.Led, inSta.getLed()); |
| | |
| | | flag = true; |
| | | } |
| | | if (!flag) { |
| | | System.out.println(staProtocol); |
| | | //TODO |
| | | News.error("" + mark + " - 1" + " - 3" + " - 堆垛机入库站信息(以下需要全true):" |
| | | + "自动信号" + staProtocol.isAutoing() + "有物信号" + staProtocol.isLoading() |
| | |
| | | + "能入信号(wms设置).equals(\"Y\")" + staDetl.getCanining()); |
| | | continue; |
| | | } |
| | | System.out.println("wrkMast:" + slave.getId() + "-" + staProtocol.getWorkNo().intValue() + "-" + crnStn.getStaNo()); |
| | | // 获取工作状态为2(设备上走)的入库工作档 |
| | | WrkMast wrkMast = wrkMastMapper.selectPakInStep2(slave.getId(), staProtocol.getWorkNo().intValue(), crnStn.getStaNo()); |
| | | System.out.println("wrkMast:" + wrkMast); |
| | | if (null == wrkMast) { |
| | | News.infoNoLog("" + mark + " - 1" + " - 4" + " - 查询无待入库数据--wrk_sts=2, 工作号={}", staProtocol.getWorkNo()); |
| | | // log.error("查询无待入库数据--wrk_sts=2, 工作号={}", staProtocol.getWorkNo()); |
| | | continue; |
| | | } |
| | | System.out.println("566"); |
| | | // 获取库位信息 |
| | | LocMast locMast = locMastService.getById(wrkMast.getLocNo()); |
| | | if (locMast == null) { |
| | | News.error("" + mark + " - 1" + " - 5" + " - 查询库存无数据--库位号{}", wrkMast.getLocNo()); |
| | | continue; |
| | | } |
| | | System.out.println("334"); |
| | | if (!locMast.getLocSts().equals("S") && !locMast.getLocSts().equals("Q")) { |
| | | News.error("" + mark + " - 1" + " - 6" + " - 入库操作库位状态不符合--状态, 库位号={},库位状态={}", wrkMast.getLocNo(), locMast.getLocSts()); |
| | | continue; |