From 9a83dbb67b223e94a946e1bf7db59336e7fb2f28 Mon Sep 17 00:00:00 2001
From: schangxiang@126.com <schangxiang@126.com>
Date: 周四, 15 5月 2025 14:51:29 +0800
Subject: [PATCH] 22

---
 PipeLineLems/server/src/CMS.Plugin.PipeLineLems.Application/Implements/SharedService.cs |   31 ++++++++++++++++++++++++++-----
 1 files changed, 26 insertions(+), 5 deletions(-)

diff --git a/PipeLineLems/server/src/CMS.Plugin.PipeLineLems.Application/Implements/SharedService.cs b/PipeLineLems/server/src/CMS.Plugin.PipeLineLems.Application/Implements/SharedService.cs
index 5b134ea..8183c36 100644
--- a/PipeLineLems/server/src/CMS.Plugin.PipeLineLems.Application/Implements/SharedService.cs
+++ b/PipeLineLems/server/src/CMS.Plugin.PipeLineLems.Application/Implements/SharedService.cs
@@ -34,12 +34,20 @@
 public class SharedService : CMSPluginAppService
 {
 
-
+    /// <summary>
+    /// 鍒嗘嫞鍔熻兘
+    /// </summary>
+    /// <param name="_serviceProvider"></param>
+    /// <param name="input"></param>
+    /// <param name="myCurrentUser"></param>
+    /// <returns></returns>
     public async Task<MesOrderResponse> CommonPick(IServiceProvider _serviceProvider, PickInput input, MyCurrentUser myCurrentUser)
     {
         //1銆佽褰曞垎鎷h褰曡〃
         //2銆佹洿鏂颁綔涓氳鍒掕〃鐨勭姸鎬� =宸插垎鎷�
         //3銆佸啓鍏� 鍒嗘嫞鍙橀噺
+        //4銆佸啓鍏ヨ拷婧姤琛�
+        //5銆佺墿鏂欑粍鐩�
 
         VariableService _variableService = _serviceProvider.GetRequiredService<VariableService>();
         var _workSectionManager = _serviceProvider.GetRequiredService<IWorkSectionManager>();
@@ -89,12 +97,13 @@
         var firstWorkPlans = await workPlanAppService.GetListByFilterAsync(x => x.PipeSpecCode == input.PipeSpecCode);
 
         var firstWorkPlan = await workPlanAppService.GetSingleByFilterAsync(x => x.PipeSpecCode == input.PipeSpecCode);
-        var rawPipe_DataIdentifier = await materialProvider.FindByNameAsync("鍒嗘嫞鍘熸枡绠℃爣璇�");
-        var rawPipe_MaterialMode = await materialProvider.FindByNameAsync("鍒嗘嫞鍘熸枡绠″瀷鍙�");
+        var rawPipe_DataIdentifier = await materialProvider.FindByNameAsync("鍘熸枡绠℃爣璇�");
+        var rawPipe_MaterialMode = await materialProvider.FindByNameAsync("鍘熸枡绠″瀷鍙�");
+        var rawPipe_Batch = await materialProvider.FindByNameAsync("鍘熸枡绠℃壒娆�");
         List<TraceMaterialModel> _MaterialParams = new List<TraceMaterialModel>();
         foreach (var item in workSection.MaterialParameters)
         {
-            if (item.Name == "鍒嗘嫞鍘熸枡绠″瀷鍙�")
+            if (item.Name == "鍘熸枡绠″瀷鍙�")
             {
                 _MaterialParams.Add(new TraceMaterialModel()
                 {
@@ -106,7 +115,7 @@
 
                 });
             }
-            if (item.Name == "鍒嗘嫞鍘熸枡绠℃爣璇�")
+            if (item.Name == "鍘熸枡绠℃爣璇�")
             {
                 _MaterialParams.Add(new TraceMaterialModel()
                 {
@@ -118,6 +127,18 @@
 
                 });
             }
+            if (item.Name == "鍘熸枡绠℃壒娆�")
+            {
+                _MaterialParams.Add(new TraceMaterialModel()
+                {
+                    Key = item.Key,
+                    Quantity = 1,
+                    MaterialId = rawPipe_Batch.MaterialId,
+                    MaterialDetailId = rawPipe_Batch.MaterialDetails.First().Id,
+                    Value = "111",//鎵规鏆傛椂鍐欐
+
+                });
+            }
         };
 
         //閰嶇疆杩囩▼鍙傛暟(閲囬泦鍙傛暟銆侀厤鏂瑰弬鏁�)

--
Gitblit v1.9.3