From 0b0899370f271793f7156144b4b912438aebdf73 Mon Sep 17 00:00:00 2001
From: heshaofeng <heshaofeng@hnkhzn.com>
Date: 星期一, 24 十一月 2025 08:41:56 +0800
Subject: [PATCH] Merge branch 'master' of http://115.159.85.185:8098/r/ZhongRui/ALDbanyunxiangmu

---
 项目代码/WMS无仓储版/WIDESEA_WMSServer/WIDESEA_StockService/StockInfoService.cs |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_StockService/StockInfoService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_StockService/StockInfoService.cs"
index f5ce2dd..7303c19 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_StockService/StockInfoService.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_StockService/StockInfoService.cs"
@@ -225,6 +225,12 @@
             return Db.Queryable<Dt_StockInfo>().Where(x => x.StockStatus == StockStatusEmun.鍏ュ簱瀹屾垚.ObjToInt() && SqlFunc.Subqueryable<Dt_LocationInfo>().Where(v => v.LocationCode == x.LocationCode && v.LocationType == locationType && v.LocationStatus == LocationStatusEnum.Pallet.ObjToInt() && (v.EnableStatus == EnableStatusEnum.OnlyOut.ObjToInt() || EnableStatusEnum.Normal.ObjToInt() == v.EnableStatus)).Any()).OrderBy(x => x.ModifyDate).First();
         }
 
+        public List<Dt_StockInfo> GetStockInfosByPalletCodes(List<string> palletCodes)
+        {
+            return Db.Queryable<Dt_StockInfo>().Where(x => palletCodes.Contains(x.PalletCode)).Includes(x => x.Details).ToList();
+        }
+
+ 
         /// <summary>
         /// 
         /// </summary>
@@ -248,6 +254,7 @@
                     LocationCode = a.LocationCode,
                     MaterielCode = b.MaterielCode,
                     MaterielName = b.MaterielName,
+                    Barcode=b.Barcode,
                     PalletCode = a.PalletCode,
                     UseableQuantity = b.StockQuantity - b.OutboundQuantity
                 }, a => locationCodes.Contains(a.LocationCode), b => b.StockQuantity > b.OutboundQuantity && b.MaterielCode == materielCode, x => true).GroupBy(x => x.PalletCode).Select(x => new StockSelectViewDTO
@@ -255,6 +262,7 @@
                     LocationCode = x.FirstOrDefault()?.LocationCode ?? "",
                     MaterielCode = x.FirstOrDefault()?.MaterielCode ?? "",
                     MaterielName = x.FirstOrDefault()?.MaterielName ?? "",
+                    Barcode=x.FirstOrDefault()?.Barcode??"",
                     PalletCode = x.Key,
                     UseableQuantity = x.Sum(x => x.UseableQuantity)
                 }).ToList();

--
Gitblit v1.9.3