From 2d7c60af5abaae8da7001e9b2db5588bd5429a09 Mon Sep 17 00:00:00 2001
From: 南骏 池 <chiffly@163.com>
Date: 星期一, 10 三月 2025 12:56:25 +0800
Subject: [PATCH] 1.受托退料

---
 service/Warehouse/InventoryManager.cs |   13 +++++++++----
 1 files changed, 9 insertions(+), 4 deletions(-)

diff --git a/service/Warehouse/InventoryManager.cs b/service/Warehouse/InventoryManager.cs
index a5fc989..c3ccba8 100644
--- a/service/Warehouse/InventoryManager.cs
+++ b/service/Warehouse/InventoryManager.cs
@@ -57,7 +57,7 @@
                 ))
             .Where((a, b) => a.DepotSectionCode == p_section_code)
             .Select((a, b) => new
-                { a.DepotSectionName, b.DepotCode, b.DepotName, b.DepotId })
+                { a.DepotSectionName, b.DepotCode, b.DepotName, b.DepotId,b.FSubsidiary })
             .Single();
 
         // 濡傛灉搴撲綅浠g爜涓嶅瓨鍦紝鍒欒繑鍥為敊璇俊鎭�
@@ -133,7 +133,8 @@
                             ? "1"
                             : "0",
                     CbillNo = c_mes_inv_item_barcodes.BillNo,
-                    Fstatus = 0
+                    Fstatus = 0,
+                    ReceiveOrgId = depotSection.FSubsidiary,
                 };
                 db.Insertable(newMesInvItemIns)
                     .IgnoreColumns(true)
@@ -173,7 +174,8 @@
                 UrgentFlag = c_mes_inv_item_barcodes.UrgentFlag,
                 BoardStyle = c_mes_inv_item_barcodes.BoardStyle,
                 TaskNo = c_mes_inv_item_barcodes.TaskNo,
-                ItemId = c_mes_inv_item_barcodes.ItemId
+                ItemId = c_mes_inv_item_barcodes.ItemId,
+                ReceiveOrgId = depotSection.FSubsidiary,
             }).IgnoreColumns(true).ExecuteCommand();
 
 
@@ -217,6 +219,7 @@
                     ? null
                     : (byte)(c_mes_inv_item_barcodes.EpFlag.Value ? 1 : 0),
                 DepotsCode = depotSection.DepotCode,
+                DepotId = depotSection.DepotId,
                 DepotsId = depotSection.DepotId,
                 DepotSectionsCode = p_section_code,
                 CheckDate = c_mes_inv_item_barcodes.CreateDate,
@@ -226,7 +229,9 @@
                 WorkLine = c_mes_inv_item_barcodes.WorkLine,
                 // ItemUnit = c_mes_inv_item_barcodes.Unit,
                 SuppNo = c_mes_inv_item_barcodes.SuppNo,
-                ItemId = c_mes_inv_item_barcodes.ItemId
+                ItemId = c_mes_inv_item_barcodes.ItemId,
+                IndepUserCode = c_user,
+                StockOrgId = depotSection.FSubsidiary,
                 // Fsubsidiary = c_organize
             }).IgnoreColumns(true).ExecuteCommand();
 

--
Gitblit v1.9.3