From ebe2da6e4eefd59b366ebab3a651b32763b580ed Mon Sep 17 00:00:00 2001
From: skyouc
Date: 星期日, 22 六月 2025 14:23:56 +0800
Subject: [PATCH] Merge branch 'ycds-wms-dev' of http://47.97.1.152:5880/r/zy-asrs-master into ycds-wms-dev

---
 zy-asrs-wms/src/main/java/com/zy/asrs/wms/asrs/timer/TaskTimer.java |   21 +++++++++++++++++++--
 1 files changed, 19 insertions(+), 2 deletions(-)

diff --git a/zy-asrs-wms/src/main/java/com/zy/asrs/wms/asrs/timer/TaskTimer.java b/zy-asrs-wms/src/main/java/com/zy/asrs/wms/asrs/timer/TaskTimer.java
index fb292e4..daf22cf 100644
--- a/zy-asrs-wms/src/main/java/com/zy/asrs/wms/asrs/timer/TaskTimer.java
+++ b/zy-asrs-wms/src/main/java/com/zy/asrs/wms/asrs/timer/TaskTimer.java
@@ -10,6 +10,8 @@
 import com.zy.asrs.wms.asrs.entity.enums.TaskStsType;
 import com.zy.asrs.wms.asrs.service.*;
 import lombok.extern.slf4j.Slf4j;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.scheduling.annotation.Scheduled;
 import org.springframework.stereotype.Component;
@@ -22,6 +24,7 @@
 @Slf4j
 @Component
 public class TaskTimer {
+    public static Logger logger = LoggerFactory.getLogger(TaskTimer.class);
 
     @Autowired
     private TaskService taskService;
@@ -87,6 +90,7 @@
                         executeTask11(task);
                         break;
                     case 53://鎷f枡鍐嶅叆搴�
+                    case 57:
                         executeTask53(task);
                         break;
                     default:
@@ -147,6 +151,7 @@
                         executeTask101(task);
                         break;
                     case 103://鎷f枡
+                    case 107:
                         executeTask103(task);
                         break;
                     default:
@@ -323,7 +328,8 @@
      * @param task
      */
     //鎷f枡鍐嶅叆搴�
-    private void executeTask53(Task task) {
+    @Transactional(rollbackFor = Exception.class)
+    public void executeTask53(Task task) {
         Long hostId = task.getHostId();
         Loc loc = locService.getOne(new LambdaQueryWrapper<Loc>().eq(Loc::getLocNo, task.getTargetLoc()).eq(Loc::getHostId, hostId));
         if (loc == null) {
@@ -381,6 +387,11 @@
         }
     }
 
+
+    /**
+     * 鏇存柊浠诲姟鏄庣粏锛屾洿鏂板簱瀛樻槑缁�
+     * @param task
+     */
     //鍑哄簱
     private void executeTask101(Task task) {
         Long hostId = task.getHostId();
@@ -390,6 +401,7 @@
             throw new CoolException("搴撲綅涓嶅瓨鍦�");
         }
         if (loc.getLocStsId() != LocStsType.R.val()) {
+            logger.error("搴撲綅锛�" + loc.getLocNo() + "锛岀姸鎬佷笉澶勪簬R.鍑哄簱棰勭害");
             throw new CoolException("搴撲綅鐘舵�佷笉澶勪簬R.鍑哄簱棰勭害");
         }
         List<TaskDetl> taskDetls = taskDetlService.getTaskDetlByTaskId(task.getId());
@@ -415,6 +427,11 @@
                 }
             }
         }
+
+
+
+
+
     }
 
     /**
@@ -431,7 +448,7 @@
         if (loc == null) {
             throw new CoolException("搴撲綅涓嶅瓨鍦�");
         }
-        if (loc.getLocStsId() != LocStsType.S.val()) {
+        if (loc.getLocStsId() != LocStsType.R.val()) {
             throw new CoolException("搴撲綅鐘舵�佷笉澶勪簬R.鍑哄簱棰勭害");
         }
         List<TaskDetl> taskDetls = taskDetlService.getTaskDetlByTaskId(task.getId());

--
Gitblit v1.9.1