From 597c2680c8a4b233791db04f076afcb8570cf6e3 Mon Sep 17 00:00:00 2001
From: Junjie <fallin.jie@qq.com>
Date: 星期二, 10 十月 2023 15:05:03 +0800
Subject: [PATCH] #
---
src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java | 55 ++++++++++++++++++++++++++++++++-----------------------
1 files changed, 32 insertions(+), 23 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 f4704d2..2975a78 100644
--- a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
+++ b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
@@ -1377,7 +1377,7 @@
continue;
}
- boolean step4 = this.locToLocExecuteStep4(wrkMast);//璋冨害杞﹁締鍙栬揣骞惰繍閫佸埌鍑哄簱鍙�
+ boolean step4 = this.locToLocExecuteStep4(wrkMast);//璋冨害杞﹁締鍙栬揣骞惰繍閫佸埌鐩爣搴撲綅
if (!step4) {
continue;
}
@@ -2021,30 +2021,39 @@
StaProtocol staProtocol317 = devpThread.getStation().get(317);
if (staProtocol303.isAutoing() && staProtocol303.isLoading() && staProtocol303.getWorkNo() != 0) {
//璋冨害鏈烘鑷�
-// //鏌ヨ鏄惁鏈夊伐浣滄。
-// WrkMast wrkMast = wrkMastMapper.selectByWorkNo(staProtocol303.getWorkNo().intValue());
-// if (wrkMast == null) {
-// continue;
-// }
-// WrkDetl wrkDetl = wrkDetlService.selectById(wrkMast.getWrkNo());
-// if (wrkDetl == null) {
-// continue;
-// }
-// RobotUtils.sendTask(staProtocol303.getWorkNo().toString(), wrkDetl.getAnfme().intValue(), "303");
- RobotUtils.sendTask(staProtocol303.getWorkNo().toString(), -1, "303");
+ //鏌ヨ鏄惁鏈夊伐浣滄。
+ WrkMast wrkMast = wrkMastMapper.selectByWorkNo(staProtocol303.getWorkNo().intValue());
+ if (wrkMast == null) {
+ continue;
+ }
+ WrkDetl wrkDetl = wrkDetlService.selectById(wrkMast.getWrkNo());
+ if (wrkDetl == null) {
+ continue;
+ }
+
+ if (wrkMast.getInvWh() == null) {
+ wrkMast.setInvWh("Y");//鏍囪宸茬粡涓嬪彂鏈烘鑷備换鍔�
+ if (wrkMastMapper.updateById(wrkMast) > 0) {
+ RobotUtils.sendTask(staProtocol303.getWorkNo().toString(), wrkDetl.getAnfme().intValue(), "303");
+ }
+ }
}else if (staProtocol317.isAutoing() && staProtocol317.isLoading() && staProtocol317.getWorkNo() != 0) {
//璋冨害鏈烘鑷�
-// //鏌ヨ鏄惁鏈夊伐浣滄。
-// WrkMast wrkMast = wrkMastMapper.selectByWorkNo(staProtocol317.getWorkNo().intValue());
-// if (wrkMast == null) {
-// continue;
-// }
-// WrkDetl wrkDetl = wrkDetlService.selectById(wrkMast.getWrkNo());
-// if (wrkDetl == null) {
-// continue;
-// }
-// RobotUtils.sendTask(staProtocol303.getWorkNo().toString(), wrkDetl.getAnfme().intValue(), "317");
- RobotUtils.sendTask(staProtocol303.getWorkNo().toString(), -1, "317");
+ //鏌ヨ鏄惁鏈夊伐浣滄。
+ WrkMast wrkMast = wrkMastMapper.selectByWorkNo(staProtocol317.getWorkNo().intValue());
+ if (wrkMast == null) {
+ continue;
+ }
+ WrkDetl wrkDetl = wrkDetlService.selectById(wrkMast.getWrkNo());
+ if (wrkDetl == null) {
+ continue;
+ }
+ if (wrkMast.getInvWh() == null) {
+ wrkMast.setInvWh("Y");//鏍囪宸茬粡涓嬪彂鏈烘鑷備换鍔�
+ if (wrkMastMapper.updateById(wrkMast) > 0) {
+ RobotUtils.sendTask(staProtocol303.getWorkNo().toString(), wrkDetl.getAnfme().intValue(), "317");
+ }
+ }
}
}
}
--
Gitblit v1.9.1