From 0023d3db5bd701864b73e57c0240c219c40c3a4e Mon Sep 17 00:00:00 2001 From: wangxinhui <wangxinhui@hnkhzn.com> Date: 星期一, 14 七月 2025 14:12:34 +0800 Subject: [PATCH] 1 --- 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_StockService/ProStockInfoService.cs | 41 ----------------------------------------- 1 files changed, 0 insertions(+), 41 deletions(-) diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_StockService/ProStockInfoService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_StockService/ProStockInfoService.cs" index 00a3ae1..07c8b06 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_StockService/ProStockInfoService.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_StockService/ProStockInfoService.cs" @@ -339,47 +339,6 @@ index++; } } - else - { - for (int i = 0; i < stockInfos.Count; i++) - { - Dt_ProStockInfo stockInfo = stockInfos[i]; - float useableStockQuantity = stockInfo.proStockInfoDetails - .Where(x => x.SaleOrder == mesRworkOutboundOrder.SaleOrder - && x.ProductCode == mesRworkOutboundOrder.ProductCode - && x.ProductVersion == mesRworkOutboundOrder.ProductVersion - && (isCanDate ? isCanDate : x.DateCode == mesRworkOutboundOrder.DateCode)) - .Sum(x => x.StockPcsQty - x.OutboundQuantity); - if (useableStockQuantity < needQuantity) - { - stockInfo.proStockInfoDetails.ForEach(x => x.OutboundQuantity = x.StockPcsQty); - needQuantity -= useableStockQuantity; - } - else - { - stockInfo.proStockInfoDetails.ForEach(x => - { - if (x.StockPcsQty > x.OutboundQuantity && x.SaleOrder == mesRworkOutboundOrder.SaleOrder - && x.ProductCode == mesRworkOutboundOrder.ProductCode - && x.ProductVersion == mesRworkOutboundOrder.ProductVersion - && (isCanDate ? isCanDate : x.DateCode == mesRworkOutboundOrder.DateCode)) - { - if (x.StockPcsQty - x.OutboundQuantity >= needQuantity) - { - x.OutboundQuantity += needQuantity; - needQuantity = 0; - } - else - { - needQuantity -= (x.StockPcsQty - x.OutboundQuantity); - x.OutboundQuantity = x.StockPcsQty; - } - } - }); - } - assignOutStocks.Add(stockInfo); - } - } residueQuantity = needQuantity; return assignOutStocks; } -- Gitblit v1.9.3