From 513da724807c2fed2d4ec772b31d054a550d391a Mon Sep 17 00:00:00 2001
From: yangpeixing <yangpeixing@hnkhzn.com>
Date: 星期三, 28 一月 2026 14:13:55 +0800
Subject: [PATCH] 1
---
WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/Service/NewOutboundOrderDetailService.cs | 17 ++++++-----------
1 files changed, 6 insertions(+), 11 deletions(-)
diff --git a/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/Service/NewOutboundOrderDetailService.cs b/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/Service/NewOutboundOrderDetailService.cs
index dcaf0c6..c5d66e5 100644
--- a/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/Service/NewOutboundOrderDetailService.cs
+++ b/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/Service/NewOutboundOrderDetailService.cs
@@ -30,7 +30,7 @@
/// <summary>
- /// 浣庢俯銆佽嵂姘村簱瀛樺垎閰�
+ /// 鎴愬搧鍒嗛厤
/// </summary>
/// <param name="outboundOrderDetails"></param>
/// <returns></returns>
@@ -114,12 +114,9 @@
}
List<Dt_StockInfo> autoAssignStocks = new List<Dt_StockInfo>();
List<IStockInfoService.residueQuantity> newResidueQuantitys = new List<IStockInfoService.residueQuantity>();
- if (warehouse.Any(x => x.WarehouseCode.Contains("DW")) || warehouse.Any(x => x.WarehouseCode.Contains("YS")))
- {
- autoAssignStocks = _stockService.StockInfoService.CPGetOutboundStocks(stockInfos, dt_OutboundOrderDetails, out List<IStockInfoService.residueQuantity> residueQuantitys);
- newResidueQuantitys.AddRange(residueQuantitys);
- outStocks.AddRange(autoAssignStocks);
- }
+ autoAssignStocks = _stockService.StockInfoService.CPGetOutboundStocks(stockInfos, dt_OutboundOrderDetails, out List<IStockInfoService.residueQuantity> residueQuantitys);
+ newResidueQuantitys.AddRange(residueQuantitys);
+ outStocks.AddRange(autoAssignStocks);
foreach (var residueQuantity in newResidueQuantitys)
{
foreach (var item in dt_OutboundOrderDetails)
@@ -149,11 +146,9 @@
palletAssignQuantity = outStockLockInfos.Where(x => x.MaterielCode == item.MaterielCode && x.PalletCode == autoAssignStocks[j].PalletCode).Sum(x => x.AssignQuantity);//鍑哄簱璇︽儏宸插垎閰嶆暟閲�
}
decimal palletOutboundQuantity = 0;
- if (warehouse.Any(x => x.WarehouseCode.Contains("DW")) || warehouse.Any(x => x.WarehouseCode.Contains("YS")))
- {
- palletOutboundQuantity = autoAssignStocks[j].Details.Where(x => x.MaterielCode == item.MaterielCode).Sum(x => x.OutboundQuantity);
- }
+ palletOutboundQuantity = autoAssignStocks[j].Details.Where(x => x.MaterielCode == item.MaterielCode).Sum(x => x.OutboundQuantity);
+
if (palletAssignQuantity < palletOutboundQuantity)//濡傛灉鍑哄簱璇︽儏宸插垎閰嶆暟閲忓皬浜庢墭鐩樺凡鍒嗛厤鏁伴噺锛屽垯鍙互缁х画娣诲姞璇ユ墭鐩樺嚭搴撲俊鎭�
{
decimal orderDetailNeedQuantity = details[i].OrderQuantity - detailAssignQuantity;
--
Gitblit v1.9.3