#
yxFwq
2024-10-21 bcdf9207ddc69ca996a1d97d2c9e74d4482e9d85
src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
@@ -139,7 +139,7 @@
                if (!Cools.isEmpty(barcode)) {
//                    log.info("{}号条码扫描器检测条码信息:{}", inSta.getBarcode(), barcode);
                    if ("NG".endsWith(barcode) || "NoRead".equals(barcode) || !CodeDetectionUtil.barcodeDetection(barcode)) {
                    if ("00000000".endsWith(barcode) || "NG".endsWith(barcode) || "NoRead".equals(barcode) || !CodeDetectionUtil.barcodeDetection(barcode)) {
                        continue;
                    }
                } else {
@@ -323,7 +323,7 @@
                if (!Cools.isEmpty(barcode)) {
//                    log.info("{}号条码扫描器检测条码信息:{}", inSta.getBarcode(), barcode);
                    if ("NG".endsWith(barcode) || "NoRead".equals(barcode) || !CodeDetectionUtil.barcodeDetection(barcode)) {
                    if ("00000000".endsWith(barcode) || "NG".endsWith(barcode) || "NoRead".equals(barcode) || !CodeDetectionUtil.barcodeDetection(barcode)) {
                        continue;
                    }
                } else {
@@ -538,7 +538,7 @@
                if (!Cools.isEmpty(barcode)) {
//                    log.info("{}号条码扫描器检测条码信息:{}", inSta.getBarcode(), barcode);
                    if ("NG".endsWith(barcode) || "NoRead".equals(barcode) || !CodeDetectionUtil.barcodeDetection(barcode)) {
                    if ("00000000".endsWith(barcode) || "NG".endsWith(barcode) || "NoRead".equals(barcode) || !CodeDetectionUtil.barcodeDetection(barcode)) {
                        continue;
                    }
                } else {
@@ -738,19 +738,7 @@
                if (!Cools.isEmpty(barcode)) {
//                    log.info("{}号条码扫描器检测条码信息:{}", inSta.getBarcode(), barcode);
                    if ("NG".endsWith(barcode) || "NoRead".equals(barcode) || !CodeDetectionUtil.barcodeDetection(barcode)) {
                        continue;
                    }
                    if ("00000000".equals(barcode)){
                        log.error(inSta+"站点,扫码失败,barcode:"+barcode);
                        // led 异常显示
                        LedThread ledThread = (LedThread) SlaveConnection.get(SlaveType.Led, inSta.getLed());
                        if (ledThread != null) {
                            ErrMsg errMsg1 = new ErrMsg();
                            errMsg1.setErrMsg(inSta+"站点,扫码失败,barcode:"+barcode);
                            errMsg1.setArea("1");
                            MessageQueue.offer(SlaveType.Led, inSta.getLed(), new Task(5, errMsg1));
                        }
                    if ("NG".endsWith(barcode) || "NoRead".equals(barcode) || "00000000".equals(barcode) || !CodeDetectionUtil.barcodeDetection(barcode)) {
                        continue;
                    }
                } else {
@@ -853,6 +841,7 @@
                        staProtocol.setStaNo(wrkMast.getStaNo());
                        devpThread.setPakMk(staProtocol.getSiteId(), false);
                        log.info("锁定标记flase===》N===》站点号:{},工作号:{},条码:{}",staProtocol.getStaNo(),staProtocol.getWorkNo(),barcode);
                        boolean result = MessageQueue.offer(SlaveType.Devp, devp.getId(), new Task(2, staProtocol));
                        if (!result) {
                            if (ledThread != null) {
@@ -901,6 +890,7 @@
                            }
                            devpThread.setPakMk(staProtocol.getSiteId(), false);
                            log.info("锁定标记flase===》N===》站点号:{},工作号:{},条码:{}",staProtocol.getStaNo(),staProtocol.getWorkNo(),barcode);
                            boolean result = MessageQueue.offer(SlaveType.Devp, devp.getId(), new Task(2, staProtocol));
                            if (!result) {
                                throw new CoolException("更新plc站点信息失败");
@@ -6039,7 +6029,7 @@
                return false;
            }
            if (steProtocol.getMode() != (short)1) {
                log.error(steNo + "号小车离线,无法操作");
//                log.error(steNo + "号小车离线,无法操作");
                return false;
            }
            if (steProtocol.getChargeStatus()!=0){
@@ -6094,7 +6084,7 @@
                return false;
            }
            if (steProtocol.getMode() != (short)1) {
                log.error(steNo + "号小车离线,无法操作");
//                log.error(steNo + "号小车离线,无法操作");
                return false;
            }
            if (steProtocol.getCharge()<31.0F && chargeSign){