From f4289ddc9cd67a8457574a8a25688c89565dc613 Mon Sep 17 00:00:00 2001
From: yusijie <ysj@hz-kingdee.com>
Date: 星期五, 29 十二月 2023 17:44:05 +0800
Subject: [PATCH] 同步生产汇报单时新增 班组,操作员 字段;删除生产汇报单时写入日志;排产模块增加工艺路线按钮

---
 WebAPI/Controllers/SCGL/日计划管理/JIT_DayPlanPlatFormBillController.cs |   57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 57 insertions(+), 0 deletions(-)

diff --git "a/WebAPI/Controllers/SCGL/\346\227\245\350\256\241\345\210\222\347\256\241\347\220\206/JIT_DayPlanPlatFormBillController.cs" "b/WebAPI/Controllers/SCGL/\346\227\245\350\256\241\345\210\222\347\256\241\347\220\206/JIT_DayPlanPlatFormBillController.cs"
index 0b956a5..c362c5f 100644
--- "a/WebAPI/Controllers/SCGL/\346\227\245\350\256\241\345\210\222\347\256\241\347\220\206/JIT_DayPlanPlatFormBillController.cs"
+++ "b/WebAPI/Controllers/SCGL/\346\227\245\350\256\241\345\210\222\347\256\241\347\220\206/JIT_DayPlanPlatFormBillController.cs"
@@ -2713,5 +2713,62 @@
         }
         #endregion
 
+        #region 鏍规嵁鐗╂枡ID鑾峰彇宸ヨ壓璺嚎 鍒楄〃
+        [Route("JIT_DayPlanPlatFormBill/GetRoutingListByMater")]
+        [HttpGet]
+        public object GetRoutingListByMater(int HMaterID, string user)
+        {
+            try
+            {
+                List<object> columnNameList = new List<object>();
+
+                int IsHavingPermissions = 1;
+
+                //鍒ゆ柇鏄惁鏈夊伐鑹鸿矾绾跨紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Gy_RoutingBill_Edit", 1, false, user))
+                {
+                    IsHavingPermissions = 0;
+                }
+
+                ds = oCN.RunProcReturn("select * from  h_v_JIT_GetRoutingList_Mater where HMaterID = " + HMaterID , "h_v_JIT_GetRoutingList_Mater");
+
+                if (ds == null || ds.Tables[0].Rows.Count == 0)
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "褰撳墠鐗╂枡娌℃湁缁存姢宸ヨ壓璺嚎锛佽鑱旂郴璁″垝閮ㄨ繘琛岀淮鎶�";
+                    objJsonResult.data = ds.Tables[0];
+                    objJsonResult.IsHavingPermissions = IsHavingPermissions;
+                    return objJsonResult;
+                }
+                else
+                {
+                    //娣诲姞鍒楀悕
+                    foreach (DataColumn col in ds.Tables[0].Columns)
+                    {
+                        Type dataType = col.DataType;
+                        string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
+                        columnNameList.Add(JsonConvert.DeserializeObject(ColmString));//鑾峰彇鍒癉ataColumn鍒楀璞$殑鍒楀悕
+                    }
+
+                    objJsonResult.code = "1";
+                    objJsonResult.count = 1;
+                    objJsonResult.Message = "Sucess锛�";
+                    objJsonResult.data = ds.Tables[0];
+                    objJsonResult.list = columnNameList;
+                    objJsonResult.IsHavingPermissions = IsHavingPermissions;
+                    return objJsonResult;
+                }
+            }
+            catch (Exception e)
+            {
+                objJsonResult.code = "0";
+                objJsonResult.count = 0;
+                objJsonResult.Message = "Exception锛�" + e.ToString();
+                objJsonResult.data = null;
+                return objJsonResult;
+            }
+        }
+        #endregion
     }
 }
\ No newline at end of file

--
Gitblit v1.9.1