From 595770fb0359d0425a103fb6e2106cecffe2c90b Mon Sep 17 00:00:00 2001
From: dengjunjie <dengjunjie@hnkhzn.com>
Date: 星期一, 30 十二月 2024 11:32:45 +0800
Subject: [PATCH] PDA添加组盘入库WMS系统,不上传上游系统

---
 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Inbound.cs |   15 +++++++++++----
 1 files changed, 11 insertions(+), 4 deletions(-)

diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Inbound.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Inbound.cs"
index a872ab6..ee27c47 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Inbound.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Inbound.cs"
@@ -44,7 +44,7 @@
                 {
                     return WebResponseContent.Instance.Error($"鏈壘鍒扮粍鐩樹俊鎭�");
                 }
-                if (stockInfo.StockStatus != StockStatusEmun.缁勭洏鏆傚瓨.ObjToInt())
+                if (stockInfo.StockStatus != StockStatusEmun.缁勭洏鏆傚瓨.ObjToInt() && stockInfo.StockStatus != StockStatusEmun.鎵嬪姩缁勭洏鏆傚瓨.ObjToInt())
                 {
                     return WebResponseContent.Instance.Error($"璇ユ墭鐩樼姸鎬佷笉姝g‘,涓嶅彲鐢宠鍏ュ簱");
                 }
@@ -71,10 +71,17 @@
                     WarehouseId = stockInfo.WarehouseId,
                     PalletType = stockInfo.PalletType
                 };
+                
 
-                stockInfo.StockStatus = StockStatusEmun.鍏ュ簱纭.ObjToInt();
-
-                _unitOfWorkManage.BeginTran();
+                if (stockInfo.StockStatus == StockStatusEmun.鎵嬪姩缁勭洏鏆傚瓨.ObjToInt())
+                {
+                    stockInfo.StockStatus = StockStatusEmun.鎵嬪姩缁勭洏鍏ュ簱纭.ObjToInt();
+                }
+                else
+                {
+                    stockInfo.StockStatus = StockStatusEmun.鍏ュ簱纭.ObjToInt();
+                }
+                    _unitOfWorkManage.BeginTran();
                 int taskId = BaseDal.AddData(newTask);
                 newTask.TaskId = taskId;
                 _stockRepository.StockInfoRepository.UpdateData(stockInfo);

--
Gitblit v1.9.3