From e98be9d02d12b0453c6267190b86fdbc11fee9fc Mon Sep 17 00:00:00 2001
From: skyouc
Date: 星期三, 28 五月 2025 12:38:49 +0800
Subject: [PATCH] Merge branch 'devlop' of http://47.97.1.152:5880/r/wms-master into devlop

---
 rsf-server/src/main/java/com/vincent/rsf/server/manager/service/impl/TaskServiceImpl.java |   13 +++++++------
 1 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/rsf-server/src/main/java/com/vincent/rsf/server/manager/service/impl/TaskServiceImpl.java b/rsf-server/src/main/java/com/vincent/rsf/server/manager/service/impl/TaskServiceImpl.java
index 341ec5b..fa3234f 100644
--- a/rsf-server/src/main/java/com/vincent/rsf/server/manager/service/impl/TaskServiceImpl.java
+++ b/rsf-server/src/main/java/com/vincent/rsf/server/manager/service/impl/TaskServiceImpl.java
@@ -582,11 +582,9 @@
                     throw new CoolException("鏇存柊缁勬墭鐘舵�佸け璐ワ紒锛�");
                 }
             }
-            Loc loc = locService.getOne(new LambdaQueryWrapper<Loc>().eq(Loc::getCode, task.getTaskType() < TaskStsType.UPDATED_IN.id ? task.getTargLoc() : task.getOrgLoc()));
-            if (null != loc
-                    && (loc.getUseStatus().equals(LocStsType.LOC_STS_TYPE_S.type)
-                    || loc.getUseStatus().equals(LocStsType.LOC_STS_TYPE_R.type))) {
 
+            Loc loc = locService.getOne(new LambdaQueryWrapper<Loc>().eq(Loc::getCode, task.getTaskType() < TaskStsType.UPDATED_IN.id ? task.getTargLoc() : task.getOrgLoc()));
+            if (null != loc && (loc.getUseStatus().equals(LocStsType.LOC_STS_TYPE_S.type) || loc.getUseStatus().equals(LocStsType.LOC_STS_TYPE_R.type))) {
                 loc.setUseStatus(LocStsType.LOC_STS_TYPE_O.type);
                 if (!locService.updateById(loc)) {
                     throw new CoolException("鏇存柊搴撲綅鐘舵�佸け璐ワ紒锛�");
@@ -607,8 +605,7 @@
                 ) {
                     basStation = basStationService.getOne(new LambdaQueryWrapper<BasStation>()
                             .eq(BasStation::getStationName, task.getTargLoc())
-                            .eq(BasStation::getUseStatus, LocStsType.LOC_STS_TYPE_R.type)
-                    );
+                            .eq(BasStation::getUseStatus, LocStsType.LOC_STS_TYPE_R.type));
                 }
                 if (null == basStation) {
                     throw new CoolException("绔欑偣鐘舵�侀敊璇紒锛�");
@@ -618,6 +615,10 @@
                     throw new CoolException("鏇存柊绔欑偣鐘舵�佸け璐ワ紒锛�");
                 }
             }
+
+            if (!taskItemService.remove(new LambdaQueryWrapper<TaskItem>().eq(TaskItem::getTaskId, task.getId()))) {
+                throw new CoolException("浠诲姟鏄庣粏鍒犻櫎澶辫触锛侊紒");
+            }
         }
         if (!this.removeByIds(Arrays.asList(ids))) {
             throw new CoolException("Delete Fail");

--
Gitblit v1.9.1