From 7fac5342ba360584d730b04f88a09265a7d7ca1d Mon Sep 17 00:00:00 2001
From: dengjunjie <dengjunjie@hnkhzn.com>
Date: 星期五, 10 一月 2025 14:35:51 +0800
Subject: [PATCH] Merge branch 'master' of http://115.159.85.185:8098/r/MeiRuiAn/HuaiAn

---
 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/OutStockLockInfoService_Pick.cs |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/OutStockLockInfoService_Pick.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/OutStockLockInfoService_Pick.cs"
index 59ae7a4..6254dbf 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/OutStockLockInfoService_Pick.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/OutStockLockInfoService_Pick.cs"
@@ -62,24 +62,27 @@
                 }
 
                 List<string> mCodes = stockInfo.Details.GroupBy(x => x.MaterielCode).Select(x => x.Key).ToList();
+                _unitOfWorkManage.BeginTran();
                 foreach (string code in mCodes)
                 {
                     _recordService.StockQuantityChangeRecordService.AddStockChangeRecord(stockInfo, updateDetailList, deleteDetailList, StockChangeTypeEnum.Outbound);
                 }
-
                 updateDetailList.ForEach(x =>
                 {
                     x.OutboundQuantity = 0;
                 });
-
+                stockInfo.StockStatus = StockStatusEmun.鎵嬪姩缁勭洏鍏ュ簱纭.ObjToInt();
                 //_stockService.StockInfoDetailService.Repository.DeleteAndMoveIntoHty(deleteDetailList, OperateTypeEnum.鑷姩瀹屾垚);
+                _stockService.StockInfoService.Repository.UpdateData(stockInfo);
                 _stockService.StockInfoDetailService.Repository.UpdateData(updateDetailList);
+                _stockService.StockInfoDetailService.Repository.DeleteData(deleteDetailList);
                 BaseDal.UpdateData(outStockLockInfos);
-
+                _unitOfWorkManage.BeginTran();
                 return WebResponseContent.Instance.OK();
             }
             catch (Exception ex)
             {
+                _unitOfWorkManage.RollbackTran();
                 return WebResponseContent.Instance.Error(ex.Message);
             }
         }

--
Gitblit v1.9.3