From 89bccb9b8fb1070f7ac5f36510c868fecead9384 Mon Sep 17 00:00:00 2001
From: wangxinhui <wangxinhui@hnkhzn.com>
Date: 星期二, 17 三月 2026 17:00:05 +0800
Subject: [PATCH] 更新
---
项目代码/WMS/WMSServices/WIDESEA_OutboundService/OutSGOrderDetailService.cs | 13 +++++++++++--
1 files changed, 11 insertions(+), 2 deletions(-)
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServices/WIDESEA_OutboundService/OutSGOrderDetailService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServices/WIDESEA_OutboundService/OutSGOrderDetailService.cs"
index 907c163..96cb2e0 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServices/WIDESEA_OutboundService/OutSGOrderDetailService.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServices/WIDESEA_OutboundService/OutSGOrderDetailService.cs"
@@ -5,6 +5,7 @@
using System.Text;
using System.Threading.Tasks;
using WIDESEA_Common.LocationEnum;
+using WIDESEA_Common.OrderEnum;
using WIDESEA_Common.StockEnum;
using WIDESEA_Core;
using WIDESEA_Core.BaseServices;
@@ -80,8 +81,17 @@
List<Dt_StockInfo> stockInfos = _stockService.StockInfoService.GetUseOldCacheStocks(item.MaterialNo, item.Width).Where(x => !palletCodes.Contains(x.PalletCode)).ToList() ?? new List<Dt_StockInfo>();
//鑾峰彇绔嬪簱鍙敤搴撳瓨
stockInfos.AddRange(_stockService.StockInfoService.GetUseableStocks(item.MaterialNo, item.Width, outBSTOrders.FirstOrDefault().WarehouseId).Where(x=>!palletCodes.Contains(x.PalletCode)).ToList());
+
+ //鑾峰彇鎵�鏈夎鐗╂枡鍗曟嵁
+ List<Dt_OutSGOrderDetail> details = outboundOrderDetails.Where(x => x.MaterialNo == item.MaterialNo && x.Width == item.Width && x.MachineName == item.MachineName).ToList();
+
if (!stockInfos.Any())
{
+ //娌℃湁鍙敤搴撳瓨锛屾爣璁颁负缂烘枡
+ foreach (var detail in details)
+ {
+ detail.OutSGOrderDetailStatus = OutOrderStatusEnum.缂烘枡.ObjToInt();
+ }
message += $"鐗╂枡锛歿item.MaterialNo},骞呭锛歿item.Width}鏃犲簱瀛橈紱";
continue;
}
@@ -90,8 +100,7 @@
List<Dt_StockInfo> autoAssignStocks = _stockService.StockInfoService.GetOutOldStocks(stockInfos, needQuantity).ToList();
//娣诲姞搴撳瓨鍒嗛厤
outStocks.AddRange(autoAssignStocks);
- //鑾峰彇鎵�鏈夎鐗╂枡鍗曟嵁
- List<Dt_OutSGOrderDetail> details = outboundOrderDetails.Where(x => x.MaterialNo == item.MaterialNo && x.Width == item.Width && x.MachineName == item.MachineName).ToList();
+
autoAssignStocks.ForEach(x =>
{
x.StockOutLength = 0;
--
Gitblit v1.9.3