From a42ae1ffc20459dc46a88590bc4a94f9280f2d3d Mon Sep 17 00:00:00 2001
From: Junjie <540245094@qq.com>
Date: 星期五, 10 五月 2024 15:31:28 +0800
Subject: [PATCH] #

---
 zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/rcs/thread/impl/NyShuttleThread.java |   21 ++++++++++++++++++++-
 1 files changed, 20 insertions(+), 1 deletions(-)

diff --git a/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/rcs/thread/impl/NyShuttleThread.java b/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/rcs/thread/impl/NyShuttleThread.java
index b0ff86f..4e4122d 100644
--- a/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/rcs/thread/impl/NyShuttleThread.java
+++ b/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/rcs/thread/impl/NyShuttleThread.java
@@ -9,6 +9,7 @@
 import com.zy.asrs.framework.common.SpringUtils;
 import com.zy.asrs.framework.exception.CoolException;
 import com.zy.asrs.wcs.common.ExecuteSupport;
+import com.zy.asrs.wcs.core.domain.param.ShuttleMoveLocParam;
 import com.zy.asrs.wcs.core.entity.BasShuttle;
 import com.zy.asrs.wcs.core.entity.Loc;
 import com.zy.asrs.wcs.core.model.MapNode;
@@ -343,10 +344,15 @@
 
     @Override
     public ShuttleProtocol getStatus() {
+        return getStatus(true);
+    }
+
+    @Override
+    public ShuttleProtocol getStatus(boolean clone) {
         if (this.shuttleProtocol == null) {
             return null;
         }
-        return this.shuttleProtocol.clone();
+        return clone ? this.shuttleProtocol.clone() : this.shuttleProtocol;
     }
 
     @Override
@@ -652,6 +658,19 @@
     }
 
     @Override
+    public boolean enableMoveLoc(ShuttleMoveLocParam param) {
+        shuttleProtocol.setMoveLoc(true);//寮�鍚窇搴�
+        shuttleProtocol.setMoveType(param.getMoveType());
+        shuttleProtocol.setXStart(param.getStartX());
+        shuttleProtocol.setXTarget(param.getTargetX());
+        shuttleProtocol.setXCurrent(param.getStartX());
+        shuttleProtocol.setYStart(param.getStartY());
+        shuttleProtocol.setYTarget(param.getTargetY());
+        shuttleProtocol.setYCurrent(param.getStartY());
+        return true;
+    }
+
+    @Override
     public ShuttleCommand getMoveCommand(Integer taskNo, String startCodeNum, String distCodeNum, Integer allDistance, Integer runDirection, Integer runSpeed, List<NavigateNode> nodes) {
         NavigateMapData navigateMapData = SpringUtils.getBean(NavigateMapData.class);
         NyShuttleHttpCommand httpStandard = getHttpStandard(Integer.parseInt(device.getDeviceNo()), taskNo);

--
Gitblit v1.9.1