From 915d3ac08ac5482e0acf7f4a90471fda3f017457 Mon Sep 17 00:00:00 2001
From: yl <ykxkd@outlook.com>
Date: 星期一, 21 十一月 2022 10:35:24 +0800
Subject: [PATCH] 工艺路线接口修改

---
 VueWebApi/DLL/DAL/KanBanManagerentDAL.cs |   36 ++++++++++++++++++++++++++++++++++++
 1 files changed, 36 insertions(+), 0 deletions(-)

diff --git a/VueWebApi/DLL/DAL/KanBanManagerentDAL.cs b/VueWebApi/DLL/DAL/KanBanManagerentDAL.cs
index e403543..b2fa817 100644
--- a/VueWebApi/DLL/DAL/KanBanManagerentDAL.cs
+++ b/VueWebApi/DLL/DAL/KanBanManagerentDAL.cs
@@ -451,6 +451,42 @@
             return mes;
         }
         #endregion
+
+
+        #region[瀵屽皵杈捐溅闂寸敓浜ф暟瀛楀寲鐪嬫澘锛屼骇绾挎暟鎹甝
+        public static ToMessage WkshpLineData(string lineCode)
+        {
+            string sql = "";
+            string search = "";
+            var dynamicParams = new DynamicParameters();
+            try
+            {
+                //鑾峰彇浜х嚎閿�鍞鍗曟姤宸ヤ俊鎭�,鎶ュ伐鏁伴噺>0  涓斿伐鍗曠姸鎬佷负闈炲叧闂姸鎬�  涓斿伐搴忎负鏈亾宸ュ簭 锛�--and (S.good_qty+S.ng_qty+S.bad_qty)<S.plan_qty)
+                sql = @"select A.saleOrderCode,A.materiel_code,M.partname,
+                        isnull(sum(S.good_qty),0) as good_qty
+                        from TKimp_Ewo A
+                        inner join TK_Wrk_Man B on A.wo=B.m_po 
+                        inner join TK_Wrk_Step S on B.wo_code=S.wo_code 
+                        inner join TFlw_Rteqp R on S.step_code=R.step_code
+                        left  join TMateriel_Info M on A.materiel_code=M.partcode
+                        where S.good_qty>0  and S.isend='Y' and R.eqp_code=@lineCode and B.status<>'CLOSED' 
+                        group by A.saleOrderCode,A.materiel_code,M.partname";
+                dynamicParams.Add("@lineCode", lineCode);
+                var data = DapperHelper.selectdata(sql, dynamicParams);
+                mes.code = "200";
+                mes.Message = "鏌ヨ鎴愬姛!";
+                mes.data = data;
+            }
+            catch (Exception e)
+            {
+                mes.code = "300";
+                mes.count = 0;
+                mes.Message = e.Message;
+                mes.data = null;
+            }
+            return mes;
+        }
+        #endregion
     }
 }
 

--
Gitblit v1.9.3