| | |
| | | back = true; |
| | | } |
| | | // 退回 |
| | | if (back && staProtocol.isInEnable() && staProtocol.isLoading() && staProtocol.isPakMk()) { |
| | | if (back && staProtocol.isInEnable() && staProtocol.isLoading() && staProtocol.isPakMk() && !staProtocol.isEmptyMk() ) { |
| | | MessageQueue.offer(SlaveType.Led, inSta.getLed(), new Task(3, errMsg)); |
| | | staProtocol.setWorkNo(wrkNo); |
| | | wrkNo++; |
| | |
| | | devpThread.setPakMk(staProtocol.getSiteId(), false); |
| | | MessageQueue.offer(SlaveType.Devp, devp.getId(), new Task(2, staProtocol)); |
| | | String errorMsg = jsonObject.getString("msg"); |
| | | log.error("全版入库回退,"+wrkNo+","+errorMsg); |
| | | if (!Cools.isEmpty(errorMsg)) { |
| | | MessageQueue.offer(SlaveType.Led, inSta.getLed(), new Task(3, errorMsg)); |
| | | } |
| | |
| | | LedCommand ledCommand = new LedCommand(); |
| | | ledCommand.setWorkNo(dto.getWorkNo()); |
| | | ledCommand.setIoType(1); |
| | | ledCommand.setTitle("全板入库"); |
| | | ledCommand.setTitle("空板入库"); |
| | | ledCommand.setLocNo(dto.getLocNo()); |
| | | ledCommand.setStaNo(dto.getStaNo()); |
| | | commands.add(ledCommand); |
| | |
| | | staProtocol.setStaNo(emptyInSta.getBackSta().shortValue()); |
| | | devpThread.setPakMk(staProtocol.getSiteId(), false); |
| | | boolean result = MessageQueue.offer(SlaveType.Devp, devp.getId(), new Task(2, staProtocol)); |
| | | String errorMsg = jsonObject.getString("msg"); |
| | | log.error("空板入库回退"+wrkNo+","+errorMsg); |
| | | if (!result) { |
| | | News.errorNoLog(""+mark+" - 2"+" - 更新plc站点信息失败"); |
| | | throw new CoolException("更新plc站点信息失败"); |
| | | } |
| | | |
| | | if (ledThread != null) { |
| | | String errorMsg = jsonObject.getString("msg"); |
| | | |
| | | if (!Cools.isEmpty(errorMsg)) { |
| | | MessageQueue.offer(SlaveType.Led, emptyInSta.getLed(), new Task(3, errorMsg)); |
| | | } |