From 2bf9814dc4e809987c6b700c4f0b191ef6765d6c Mon Sep 17 00:00:00 2001 From: yxFwq <1> Date: 星期二, 11 二月 2025 08:03:47 +0800 Subject: [PATCH] # --- src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java | 62 ++++++++++++++++++++++++++++-- 1 files changed, 57 insertions(+), 5 deletions(-) diff --git a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java index 908914e..7286ebe 100644 --- a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java +++ b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java @@ -2882,7 +2882,13 @@ wrkMast.setUpdMk("Y"); wrkMastMapper.updateById(wrkMast); // 鐢熸垚宸ヤ綔妗�,灏嗘祬搴撲綅绉昏浆鍒版柊鐨勫簱浣嶄腑 - moveLocForDeepLoc(slave, shallowLoc); + try{ + moveLocForDeepLoc(slave, shallowLoc); + } catch (Exception e){ + log.error("{}浠诲姟鍑哄簱澶辫触锛屾祬搴撲綅鍫靛锛佸紓甯�", wrkMast.getWrkNo(), e); + log.error("{}浠诲姟鍑哄簱澶辫触锛屾祬搴撲綅鍫靛锛佹祬搴撲綅鍙�:{}", wrkMast.getWrkNo(), shallowLocNo); + continue; + } } log.error("{}浠诲姟鍑哄簱澶辫触锛屾祬搴撲綅鍫靛锛佹祬搴撲綅鍙�:{}", wrkMast.getWrkNo(), shallowLocNo); continue; @@ -3096,6 +3102,13 @@ } Integer turnBigInt = 0; + if (wrkMast.booleanStaNoSign() && wrkMast.getIoPri()<99D){ + Date now = new Date(); + long differenceInSeconds = now.getTime() - wrkMast.getModiTime().getTime(); + if (differenceInSeconds<=2000){ + continue; + } + } // if (wrkMast.booleanStaNoSign()){ // RgvOneSign rgvOneSign = rgvOneSignMapper.selectOneSign("LineUp"+wrkMast.getStaNo()); // if (Cools.isEmpty(rgvOneSign)){ @@ -5165,7 +5178,7 @@ break; } if (count>0){ - if (jarOtherProtocol.getJarTemperature()<jarTemperature){ + if (jarOtherProtocol.getJarTemperature()<jarTemperature && jarOtherProtocol.modeType == JarModeType.AUTO){ break; } } @@ -5176,7 +5189,7 @@ // if (jarOtherProtocol == null) { // break; // } - if (jarOtherProtocol.getJarTemperature()>jarTemperature){ + if (jarOtherProtocol.getJarTemperature()>jarTemperature || jarOtherProtocol.modeType != JarModeType.AUTO){ log.info("{}鍙风~鍖栫綈鏌ヨ璁惧娓╁害杩囬珮锛岀瓑寰呴檷娓�....鍏堟墽琛屽叆缃愪换鍔★紒锛侊紒",jarOtherProtocol.getJarNo()); } else { if (basJarMastService.getJarMastByJarIdCount(jarSlave.getId())>0){ @@ -5902,6 +5915,42 @@ add(8); }}); if (basJarMastList.isEmpty()){ + return false; + } + + StaProtocol staProtocolEnd = new StaProtocol(); + staProtocolEnd.setAutoing(false); + for (DevpSlave devp : slaveProperties.getDevp()) { + if (devp.getId() == 1){ + continue; + } + // 閬嶅巻鍏ュ簱鍙� + for (DevpSlave.Sta inSta : devp.getOutJarInSta()) { + if (jarSlave.getId() == 1 || jarSlave.getId() == 2){ + if (inSta.getStaNo() == 627){ + SiemensDevpThread devpThread = (SiemensDevpThread) SlaveConnection.get(SlaveType.Devp, devp.getId()); + StaProtocol staProtocol = devpThread.getStation().get(inSta.getStaNo()); + if (staProtocol == null) { + break; + } + staProtocolEnd = staProtocol; + break; + } + } else if (jarSlave.getId() == 3 || jarSlave.getId() == 4){ + if (inSta.getStaNo() == 628){ + SiemensDevpThread devpThread = (SiemensDevpThread) SlaveConnection.get(SlaveType.Devp, devp.getId()); + StaProtocol staProtocol = devpThread.getStation().get(inSta.getStaNo()); + if (staProtocol == null) { + break; + } + staProtocolEnd = staProtocol; + break; + } + } + + } + } + if (!staProtocolEnd.isAutoing() || staProtocolEnd.isLoading()){ return false; } List<BasJarMast> basJarMastList10 = basJarMastService.getJarMastByJarIdAndStatusList(jarSlave.getId(), new ArrayList<Integer>() {{ @@ -8279,7 +8328,7 @@ log.error("纭寲缃怞ar鍛戒护涓嬪彂澶辫触锛宩ar鍙�={},浠诲姟鏁版嵁={},纭寲缃愭暟鎹�={},sign={}", execute.getJarId(), JSON.toJSON(execute), JSON.toJSON(jarProtocol),sign); } - return true; + continue; } for (WrkMastExecute wrkMastExecute : wrkMastExecuteList){ if (wrkMastExecute.getIoType() == 2 || wrkMastExecute.getIoType() == 4){ @@ -8294,7 +8343,7 @@ wrkMastExecute.getSteId(), JSON.toJSON(wrkMastExecute), JSON.toJSON(jarProtocol),sign); return false; } - return true; + continue; } } } @@ -8870,6 +8919,9 @@ public synchronized void stackingCompletionDriveTray2() { SiemensDevpThread devpThread = (SiemensDevpThread) SlaveConnection.get(SlaveType.Devp, 2); StaProtocol staProtocol = devpThread.getStation().get(518); + if (Cools.isEmpty(staProtocol)) { + return; + } String barcode = staProtocol.getBarcode(); if (!Cools.isEmpty(barcode)) { if ("NG".endsWith(barcode) || "NoRead".equals(barcode) || "00000000".equals(barcode) || !CodeDetectionUtil.barcodeDetection(barcode)) { -- Gitblit v1.9.1