From b67b1c28ef34c89cd1420ad5c414533658bc7206 Mon Sep 17 00:00:00 2001
From: YL <YL@LAPTOP-SE03PLUR>
Date: 星期一, 07 二月 2022 22:09:09 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-API

---
 WebAPI/Controllers/生产管理/报工台工序/Sc_MaterToSourceStepBillController.cs |   64 +++--
 WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs              |   62 ++++-
 WebAPI/Controllers/生产管理/报工台工序/Sc_MESEndStepWorkBillController.cs    |   13 +
 WebAPI/Controllers/CJGL/Sc_ProcessExchangeBillController.cs         |   12 +
 WebAPI/Controllers/LMESController.cs                                |   12 +
 WebAPI/Controllers/生产管理/报工台工序/Sc_MESStopStepWorkBillController.cs   |   14 +
 WebAPI/Controllers/CJGL/Cj_StationInBillController.cs               |   48 +++
 WebAPI/Controllers/CJGL/Cj_StationEntrustOutBillController.cs       |   60 ++++-
 WebAPI/Controllers/生产管理/报工台工序/Sc_MESBeginStepWorkBillController.cs  |   13 +
 WebAPI/Controllers/Sc_GroupOrderBillController.cs                   |    1 
 WebAPI/Controllers/CJGL/Cj_StationEntrustInBillController.cs        |   56 ++++-
 WebAPI/Controllers/Sc_ProcessMangementController.cs                 |  180 ++++++++++++++--
 WebAPI/WebAPI.csproj                                                |    2 
 WebAPI/Controllers/SCGL/Sc_ICBomBillController.cs                   |   71 ++++++
 14 files changed, 507 insertions(+), 101 deletions(-)

diff --git a/WebAPI/Controllers/CJGL/Cj_StationEntrustInBillController.cs b/WebAPI/Controllers/CJGL/Cj_StationEntrustInBillController.cs
index ab7d2b1..e84c7db 100644
--- a/WebAPI/Controllers/CJGL/Cj_StationEntrustInBillController.cs
+++ b/WebAPI/Controllers/CJGL/Cj_StationEntrustInBillController.cs
@@ -24,10 +24,20 @@
         #region 杩斿洖濮斿宸ュ簭鍙戝嚭鍗曞垪琛�
         [Route("Cj_StationEntrustInBill/list")]
         [HttpGet]
-        public object list(string sWhere)
+        public object list(string sWhere,string user)
         {
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("MES_StationEntrustInBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳煡璇㈡潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (sWhere == null || sWhere.Equals(""))
                 {
                     ds = oCN.RunProcReturn("select * from h_v_MES_StationEntrustInBillList " + sWhere+ " order by 鍙戝嚭鏃堕棿 desc", "h_v_MES_StationEntrustInBillList");
@@ -125,11 +135,24 @@
         {
             var _value = oMain["oMain"].ToString();
             string msg1 = _value.ToString();
+            string[] sArray = msg1.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries);
             try
             {
                 //濮斿宸ュ簭鍙戝嚭鍙嶅簭鍒楀寲
-                msg1 = "[" + msg1.ToString() + "]";
-                List<StationBill> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<StationBill>>(msg1); 
+               string msg2 = "[" + sArray[0].ToString() + "]";
+               string user = sArray[1].ToString();
+
+                //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("MES_StationEntrustInBill_Edit", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犵紪杈戞潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
+                List<StationBill> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<StationBill>>(msg2); 
                 long HMainInterID = 0;
                 HMainInterID = list[0].HMainInterID;
                 string eventType = list[0].eventType;
@@ -546,14 +569,15 @@
             try
             {
                 //瀹℃牳鏉冮檺
-                //if (!DBUtility.ClsPub.Security_Log("MES_StationEntrustInBill_Check", 1, false, CurUserName))
-                //{
-                //    objJsonResult.code = "0";
-                //    objJsonResult.count = 0;
-                //    objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�";
-                //    objJsonResult.data = null;
-                //    return objJsonResult;
-                //}
+                if (!DBUtility.ClsPub.Security_Log("MES_StationEntrustInBill_Check", 1, false, CurUserName))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (HInterID == 0)
                 {
                     objJsonResult.code = "0";
@@ -649,6 +673,16 @@
         {
             try
             {
+                //瀹℃牳鏉冮檺
+                if (!DBUtility.ClsPub.Security_Log("MES_StationEntrustInBill_Check", 1, false, CurUserName))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鍙嶅鏍稿け璐ワ紒鏃犳潈闄愶紒";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (HInterID == 0)
                 {
                     objJsonResult.code = "0";
diff --git a/WebAPI/Controllers/CJGL/Cj_StationEntrustOutBillController.cs b/WebAPI/Controllers/CJGL/Cj_StationEntrustOutBillController.cs
index fc70373..e1d0d2e 100644
--- a/WebAPI/Controllers/CJGL/Cj_StationEntrustOutBillController.cs
+++ b/WebAPI/Controllers/CJGL/Cj_StationEntrustOutBillController.cs
@@ -24,10 +24,20 @@
         #region 杩斿洖濮斿宸ュ簭鎺ユ敹鍗曞垪琛�
         [Route("Cj_StationEntrustOutBill/list")]
         [HttpGet]
-        public object list(string sWhere)
+        public object list(string sWhere,string user)
         {
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("MES_StationEntrustOutBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳煡璇㈡潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (sWhere == null || sWhere.Equals(""))
                 {
                     ds = oCN.RunProcReturn("select * from h_v_MES_StationEntrustOutBillList " + sWhere+ " order by 鎺ユ敹鏃堕棿 desc", "h_v_MES_StationEntrustOutBillList");
@@ -73,11 +83,24 @@
         {
             var _value = oMain["oMain"].ToString();
             string msg1 = _value.ToString();
+            string[] sArray = msg1.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries);
             try
             {
                 //閮ㄩ棬鍩虹璧勬枡鍙嶅簭鍒楀寲
-                msg1 = "[" + msg1.ToString() + "]";
-                List<StationBill> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<StationBill>>(msg1);
+               string msg2 = "[" + sArray[0].ToString() + "]";
+                string user = sArray[1].ToString();
+
+                //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("MES_StationEntrustOutBill_Edit", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犵紪杈戞潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
+                List<StationBill> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<StationBill>>(msg2);
                 long HMainInterID = 0;
                 HMainInterID = list[0].HMainInterID;
                 string eventType = list[0].eventType;
@@ -583,16 +606,16 @@
         {
             try
             {
-                //string ModRightNameCheck = "MES_StationEntrustOutBill_Check";
-                ////瀹℃牳鏉冮檺
-                //if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
-                //{
-                //    objJsonResult.code = "0";
-                //    objJsonResult.count = 0;
-                //    objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�";
-                //    objJsonResult.data = null;
-                //    return objJsonResult;
-                //}
+                string ModRightNameCheck = "MES_StationEntrustOutBill_Check";
+                //瀹℃牳鏉冮檺
+                if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
                 if (HInterID == 0)
                 {
                     objJsonResult.code = "0";
@@ -699,6 +722,17 @@
         {
             try
             {
+                string ModRightNameCheck = "MES_StationEntrustOutBill_Check";
+                //瀹℃牳鏉冮檺
+                if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鍙嶅鏍稿け璐ワ紒鏃犳潈闄愶紒";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (HInterID == 0)
                 {
                     objJsonResult.code = "0";
diff --git a/WebAPI/Controllers/CJGL/Cj_StationInBillController.cs b/WebAPI/Controllers/CJGL/Cj_StationInBillController.cs
index a3e5a06..a87e6e8 100644
--- a/WebAPI/Controllers/CJGL/Cj_StationInBillController.cs
+++ b/WebAPI/Controllers/CJGL/Cj_StationInBillController.cs
@@ -30,14 +30,30 @@
         {
             var _value = oMain["oMain"].ToString();
             string msg1 = _value.ToString();
+            string[] sArray = msg1.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries);
             try
             {
                 //濮斿宸ュ簭鍙戝嚭鍙嶅簭鍒楀寲
-                msg1 = "[" + msg1.ToString() + "]";
-                List<StationBill> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<StationBill>>(msg1);
+                string msg2 = "[" + sArray[0].ToString() + "]";
+                string user = sArray[1].ToString();
+
+                //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Cj_StationInBill_Edit", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犵紪杈戞潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
+                List<StationBill> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<StationBill>>(msg2);
                 long HMainInterID = 0;
                 HMainInterID = list[0].HMainInterID;
                 long HProcExchInterID = list[0].lngBillKey;//娴佽浆鍗′富鍐呯爜
+
+               
+
                 if (HProcExchInterID <= 0)
                 {
                     objJsonResult.code = "0";
@@ -363,10 +379,20 @@
         #region 杩斿洖宸ュ簭杩涚珯鎺ユ敹鍗曞垪琛�
         [Route("Cj_StationInBill/get_Display")]
         [HttpGet]
-        public object get_Display(string sWhere)
+        public object get_Display(string sWhere,string user)
         {
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Cj_StationInBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳煡璇㈡潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (sWhere == null || sWhere.Equals(""))
                 {
                     ds = oCN.RunProcReturn("select * from h_v_MES_StationInBillList " + sWhere+ " order by 杩涚珯鏃堕棿 desc", "h_v_MES_StationInBillList");
@@ -492,7 +518,7 @@
         {
             try
             {
-                string ModRightNameCheck = "MES_StationInBill_Check";
+                string ModRightNameCheck = "Cj_StationInBill_Check";
                 //瀹℃牳鏉冮檺
                 if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false,CurUserName))
                 {
@@ -609,6 +635,17 @@
         {
             try
             {
+                string ModRightNameCheck = "Cj_StationInBill_Check";
+                //瀹℃牳鏉冮檺
+                if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鍙嶅鏍稿け璐ワ紒鏃犳潈闄愶紒";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (HInterID == 0)
                 {
                     objJsonResult.code = "0";
@@ -789,9 +826,8 @@
         {
             try
             {
-
                 //缂栬緫鏉冮檺
-                if (!DBUtility.ClsPub.Security_Log("MES_StationInBill_Delete", 1, false, HDeleteMan))
+                if (!DBUtility.ClsPub.Security_Log("Cj_StationInBill_Drop", 1, false, HDeleteMan))
                 {
                     objJsonResult.code = "0";
                     objJsonResult.count = 0;
diff --git a/WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs b/WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs
index d3874e3..6091287 100644
--- a/WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs
+++ b/WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs
@@ -31,11 +31,25 @@
         {
             var _value = oMain["oMain"].ToString();
             string msg1 = _value.ToString();
+            string[] sArray = msg1.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries);
             try
             {
                 //鍙嶅簭鍒楀寲
-                msg1 = "[" + msg1.ToString() + "]";
-                List<StationBill> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<StationBill>>(msg1);
+                string msg2 = "[" + sArray[0].ToString() + "]";
+                string user = sArray[1].ToString();//鐢ㄦ埛鍚�
+
+                //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Cj_StationOutBill_Edit", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犵紪杈戞潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
+
+                List<StationBill> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<StationBill>>(msg2);
                 long HMainInterID = 0;
                 HMainInterID = list[0].HMainInterID;
                 string eventType = list[0].eventType;
@@ -400,10 +414,20 @@
         #region 杩斿洖宸ュ簭鍑虹珯姹囨姤鍗曞垪琛�
         [Route("Cj_StationOutBill/get_Display")]
         [HttpGet]
-        public object get_Display(string sWhere)
+        public object get_Display(string sWhere,string user)
         {
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Cj_StationOutBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳煡璇㈡潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (sWhere == null || sWhere.Equals(""))
                 {
                     ds = oCN.RunProcReturn("select * from h_v_MES_StationOutBillList " + sWhere + " order by 鍑虹珯鏃堕棿 desc", "h_v_MES_StationOutBillList");
@@ -682,7 +706,7 @@
             {
 
                 //缂栬緫鏉冮檺
-                if (!DBUtility.ClsPub.Security_Log("MES_StationOutBill_Delete", 1, false, HDeleteMan))
+                if (!DBUtility.ClsPub.Security_Log("Cj_StationOutBill_Drop", 1, false, HDeleteMan))
                 {
                     objJsonResult.code = "0";
                     objJsonResult.count = 0;
@@ -822,16 +846,17 @@
         {
             try
             {
-                //string ModRightNameCheck = "MES_StationOutBill_Check";
+                string ModRightNameCheck = "Cj_StationOutBill_Check";
                 ////瀹℃牳鏉冮檺
-                //if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
-                //{
-                //    objJsonResult.code = "0";
-                //    objJsonResult.count = 0;
-                //    objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�";
-                //    objJsonResult.data = null;
-                //    return objJsonResult;
-                //}
+                if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (HInterID == 0)
                 {
                     objJsonResult.code = "0";
@@ -939,6 +964,17 @@
         {
             try
             {
+                string ModRightNameCheck = "Cj_StationOutBill_Check";
+                ////瀹℃牳鏉冮檺
+                if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鍙嶅鏍稿け璐ワ紒鏃犳潈闄愶紒";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (HInterID == 0)
                 {
                     objJsonResult.code = "0";
diff --git a/WebAPI/Controllers/CJGL/Sc_ProcessExchangeBillController.cs b/WebAPI/Controllers/CJGL/Sc_ProcessExchangeBillController.cs
index 337127e..f550ae7 100644
--- a/WebAPI/Controllers/CJGL/Sc_ProcessExchangeBillController.cs
+++ b/WebAPI/Controllers/CJGL/Sc_ProcessExchangeBillController.cs
@@ -38,6 +38,18 @@
             string[] sArray = msg1.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries);
             string msg2 = sArray[0].ToString();
             string msg3 = sArray[1].ToString();
+            string user = sArray[2].ToString();//鐢ㄦ埛鍚�
+
+            //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+            if (!DBUtility.ClsPub.Security_Log("Sc_ProcessExchangeBill_Edit", 1, false, user))
+            {
+                objJsonResult.code = "0";
+                objJsonResult.count = 0;
+                objJsonResult.Message = "鏃犵紪杈戞潈闄�!";
+                objJsonResult.data = null;
+                return objJsonResult;
+            }
+
             bool bResult;
             try
             {
diff --git a/WebAPI/Controllers/LMESController.cs b/WebAPI/Controllers/LMESController.cs
index 3759f2b..b6b1796 100644
--- a/WebAPI/Controllers/LMESController.cs
+++ b/WebAPI/Controllers/LMESController.cs
@@ -54,11 +54,21 @@
         /// </summary>
         [Route("LEMS/MES_Sc_ProcessExchangeBillQuery_Json")]
         [HttpGet]
-        public object MES_Sc_ProcessExchangeBillList_Json(string sWhere)
+        public object MES_Sc_ProcessExchangeBillList_Json(string sWhere,string user)
         {
             DataSet ds;
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Sc_ProcessExchangeBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳煡璇㈡潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                 ds = oCN.RunProcReturn("select * from h_v_Sc_ProcessExchangeBillQuery where 1 = 1 " + sWhere, "h_v_Sc_ProcessExchangeBillQuery");
                 if (ds == null || ds.Tables[0].Rows.Count <= 0)
diff --git a/WebAPI/Controllers/SCGL/Sc_ICBomBillController.cs b/WebAPI/Controllers/SCGL/Sc_ICBomBillController.cs
new file mode 100644
index 0000000..d2fb0ba
--- /dev/null
+++ b/WebAPI/Controllers/SCGL/Sc_ICBomBillController.cs
@@ -0,0 +1,71 @@
+锘縰sing System;
+using System.Collections.Generic;
+using System.Data;
+using System.Linq;
+using System.Web;
+using System.Web.Http;
+using WebAPI.Models;
+
+namespace WebAPI.Controllers.SCGL
+{
+    public class Sc_ICBomBillController : ApiController
+    {
+        private json objJsonResult = new json();
+        SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
+        DataSet ds;
+        public DAL.ClsSc_ICMOReportBill BillNew = new DAL.ClsSc_ICMOReportBill();   //瀵瑰簲鍗曟嵁绫�
+        public DAL.ClsSc_ICMOReportBill BillOld = new DAL.ClsSc_ICMOReportBill();   //瀵瑰簲鍗曟嵁绫�
+
+        #region 鐢熶骇鐗╂枡娓呭崟  鏌ヨ
+        /// <summary>
+        /// 鐢熶骇BOM/鐢熶骇鐗╂枡娓呭崟
+        /// </summary>
+        /// <param name="sWhere"></param>
+        /// <param name="user"></param>
+        /// <returns></returns>
+        [Route("Sc_ICBomBill/list")]
+        [HttpGet]
+        public object list(string sWhere, string user)
+        {
+            try
+            {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Gy_ICBomBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愭煡璇�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
+                if (sWhere == null || sWhere.Equals(""))
+                {
+                    ds = oCN.RunProcReturn("select * from h_v_Gy_ICBomBillList " + sWhere, "h_v_Gy_ICBomBillList");
+                }
+                else
+                {
+                    string sql1 = "select * from h_v_Gy_ICBomBillList where 1 = 1 ";
+                    string sql = sql1 + sWhere;
+                    ds = oCN.RunProcReturn(sql, "h_v_Gy_ICBomBillList");
+                }
+
+                objJsonResult.code = "1";
+                objJsonResult.count = 1;
+                objJsonResult.Message = "Sucess锛�";
+                objJsonResult.data = ds.Tables[0];
+                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
diff --git a/WebAPI/Controllers/Sc_GroupOrderBillController.cs b/WebAPI/Controllers/Sc_GroupOrderBillController.cs
index 09e4d6e..ac7ffc1 100644
--- a/WebAPI/Controllers/Sc_GroupOrderBillController.cs
+++ b/WebAPI/Controllers/Sc_GroupOrderBillController.cs
@@ -22,6 +22,7 @@
 
         /// <summary>
         /// 杩斿洖鍒楄〃
+        /// 浜х嚎缁勬墭鍗曞垪琛�
         /// </summary>
         /// <param name="sWhere">鎷兼帴鐨凷QL</param>
         /// <returns>object</returns>
diff --git a/WebAPI/Controllers/Sc_ProcessMangementController.cs b/WebAPI/Controllers/Sc_ProcessMangementController.cs
index ee872f5..2dc594c 100644
--- a/WebAPI/Controllers/Sc_ProcessMangementController.cs
+++ b/WebAPI/Controllers/Sc_ProcessMangementController.cs
@@ -104,11 +104,21 @@
         /// </summary>
         [Route("Sc_ProcessMangement/MES_Sc_ProcessReportList_Json")]
         [HttpGet]
-        public object MES_Sc_ProcessReportList_Json(string sWhere)
+        public object MES_Sc_ProcessReportList_Json(string sWhere,string user)
         {
             DataSet ds;
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Sc_ICMOReportBillQuery", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愭煡璇�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                 if (sWhere == null || sWhere.Equals(""))
                 {
@@ -236,11 +246,20 @@
         /// </summary>
         [Route("Sc_ProcessMangement/MES_Sc_ProcessPlanMain_Json")]
         [HttpGet]
-        public object MES_Sc_ProcessPlanMain_Json(string sWhere)
+        public object MES_Sc_ProcessPlanMain_Json(string sWhere,string user)
         {
             DataSet ds;
             try
             {
+                //if (!DBUtility.ClsPub.Security_Log("Sc_ProcessPlan_Query", 1, false, user))
+                //{
+                //    objJsonResult.code = "0";
+                //    objJsonResult.count = 0;
+                //    objJsonResult.Message = "鏃犳潈闄愭煡璇�!";
+                //    objJsonResult.data = null;
+                //    return objJsonResult;
+                //}
+
                 SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                 if (sWhere == null || sWhere.Equals(""))
                 {
@@ -301,8 +320,19 @@
 
             int hentryid = int.Parse(sArray[2].ToString());//瀛愯〃鐨勯『搴廼d
             int OperationType = int.Parse(sArray[3].ToString());//鏁版嵁绫诲瀷 1娣诲姞 3淇敼
+            string user = sArray[4].ToString();//鐢ㄦ埛鍚�
             try
             {
+                //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Sc_ProcessPlan_Edit", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愮紪杈�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 omodel = Newtonsoft.Json.JsonConvert.DeserializeObject<ClsSc_ProcessPlanMain>(msg2);
                 string BillType = "3715";
 
@@ -426,20 +456,20 @@
         [HttpGet]
         public object CheckDeOAuditBill(int HInterID, int IsAudit, string CurUserName)
         {
-            //    string ModRightNameCheck = ""; 璇ユā鍧楃殑瀹℃牳鍔熻兘
+            string ModRightNameCheck = "Sc_ProcessPlan_Check"; //璇ユā鍧楃殑瀹℃牳鍔熻兘
             DBUtility.ClsPub.CurUserName = CurUserName;//瀛樺偍鐢ㄦ埛鍚�
 
             try
             {
-                ////鍒ゆ柇鏄惁鏈夊鏍告潈闄�
-                //    if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
-                //{
-                //    objJsonResult.code = "0";
-                //    objJsonResult.count = 0;
-                //    objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�";
-                //    objJsonResult.data = null;
-                //    return objJsonResult;
-                //}
+                //鍒ゆ柇鏄惁鏈夊鏍告潈闄�
+                if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
 
                 //鍒ゆ柇id鏄惁澶т簬0
                 if (HInterID <= 0)
@@ -611,14 +641,15 @@
             try
             {
                 //鍒ゆ柇鏉冮檺
-                //if (!DBUtility.ClsPub.Security_Log(ModRightNameDelete, 1, false, User))
-                //{
-                //    objJsonResult.code = "0";
-                //    objJsonResult.count = 0;
-                //    objJsonResult.Message = "娌℃湁鍒犻櫎鏉冮檺";
-                //    objJsonResult.data = null;
-                //    return objJsonResult;
-                //}
+                if (!DBUtility.ClsPub.Security_Log(ModRightNameDelete, 1, false, User))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "娌℃湁鍒犻櫎鏉冮檺";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 oBill.ShowBill(HInterID, ref DBUtility.ClsPub.sExeReturnInfo);
 
                 if (oBill.omodel.HChecker != "")
@@ -667,11 +698,21 @@
         /// <returns></returns>
         [Route("Sc_ProcessMangement/MES_Sc_ProcessSendWorkMain_Json")]
         [HttpGet]
-        public object MES_Sc_ProcessSendWorkMain_Json(string sWhere)
+        public object MES_Sc_ProcessSendWorkMain_Json(string sWhere,string user)
         {
             DataSet ds;
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Sc_ProcessSendWork_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愭煡璇�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                 if (sWhere == null || sWhere.Equals(""))
                 {
@@ -710,11 +751,23 @@
             string msg2 = sArray[0].ToString();
             string msg3 = sArray[1].ToString();
 
+            string user = sArray[2].ToString();//鐢ㄦ埛鍚�
+
             string UserName = "";
             ListModels oListModels = new ListModels();
 
             try
             {
+                //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Sc_ProcessSendWork_Edit", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愮紪杈�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 DAL.ClsSc_ProcessSendWork Sendwork = new DAL.ClsSc_ProcessSendWork();
                 List<Model.ClsSc_ProcessSendWorkMain> lsmain = new List<Model.ClsSc_ProcessSendWorkMain>();
                 msg2 = msg2.Replace("\\", "");
@@ -886,11 +939,23 @@
             string msg2 = sArray[0].ToString();
             string msg3 = sArray[1].ToString();
 
+            string user = sArray[2].ToString();
+
             string UserName = "";
             ListModels oListModels = new ListModels();
 
             try
             {
+                //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("WW_EntrustProcSendWorkBill_Edit", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愮紪杈�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 WebAPI.DLL.ClsSc_ProcessSendWork Sendwork = new WebAPI.DLL.ClsSc_ProcessSendWork();
                 List<WebAPI.Models.ClsSc_ProcessSendWorkMain> lsmain = new List<WebAPI.Models.ClsSc_ProcessSendWorkMain>();
                 msg2 = msg2.Replace("\\", "");
@@ -1327,10 +1392,21 @@
             string[] sArray = msg1.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries);
             string msg2 = sArray[0].ToString();
             string msg3 = sArray[1].ToString();
+
+            string user = sArray[2].ToString();//鐢ㄦ埛鍚�
             string UserName;
             ListModels oListModels = new ListModels();
             try
             {
+                //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Sc_ICMOReportBill_Edit", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愮紪杈�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
                 DAL.ClsSc_ProcessReport ReportModel = new DAL.ClsSc_ProcessReport();
                 List<Model.ClsSc_ProcessReportMain> lsmain = new List<Model.ClsSc_ProcessReportMain>();
                 msg2 = msg2.Replace("\\", "");
@@ -1910,11 +1986,21 @@
         /// <returns></returns>
         [Route("Sc_ProcessMangement/MES_WW_EntrustProcSendWorkBill_Json")]
         [HttpGet]
-        public object MES_WW_EntrustProcSendWorkBill_Json(string sqlWhere)
+        public object MES_WW_EntrustProcSendWorkBill_Json(string sqlWhere,string user)
         {
             DataSet ds;
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("WW_EntrustProcSendWorkBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愭煡璇�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                 if (sqlWhere == null || sqlWhere.Equals(""))
                 {
@@ -1945,11 +2031,21 @@
         /// <returns></returns>
         [Route("Sc_ProcessMangement/MES_WW_EntrustProcessReportBill_Json")]
         [HttpGet]
-        public object MES_WW_EntrustProcessReportBill_Json(string sqlWhere)
+        public object MES_WW_EntrustProcessReportBill_Json(string sqlWhere,string user)
         {
             DataSet ds;
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("WW_EntrustProcessReportBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愭煡璇�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                 if (sqlWhere == null || sqlWhere.Equals(""))
                 {
@@ -1979,12 +2075,22 @@
         /// <param name="sqlWhere"></param>
         /// <returns></returns>
         [Route("Sc_ProcessMangement/MES_WW_EntrustProcessSendOutBillList_Json")]
-        [HttpGet]
-        public object MES_WW_EntrustProcessSendOutBillList_Json(string sqlWhere)
+        [HttpGet] 
+        public object MES_WW_EntrustProcessSendOutBillList_Json(string sqlWhere,string user)
         {
             DataSet ds;
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("WW_EntrustProcessSendOutBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愭煡璇�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                 if (sqlWhere == null || sqlWhere.Equals(""))
                 {
@@ -2024,11 +2130,23 @@
             string msg2 = sArray[0].ToString();
             string msg3 = sArray[1].ToString();
 
+            string user = sArray[2].ToString();//鐢ㄦ埛鍚�
+
             string UserName = "";
             ListModels oListModels = new ListModels();
 
             try
             {
+                //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("WW_EntrustProcessReportBill_Edit", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愮紪杈�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 WebAPI.DLL.ClsWW_EntrustProcessReportBill Sendwork = new WebAPI.DLL.ClsWW_EntrustProcessReportBill();
                 List<WebAPI.Models.ClsWW_EntrustProcessReportBillMain> lsmain = new List<WebAPI.Models.ClsWW_EntrustProcessReportBillMain>();
                 msg2 = msg2.Replace("\\", "");
@@ -2332,11 +2450,23 @@
             string msg2 = sArray[0].ToString();
             string msg3 = sArray[1].ToString();
 
+            string user = sArray[1].ToString();//鐢ㄦ埛鍚�
+
             string UserName = "";
             ListModels oListModels = new ListModels();
 
             try
             {
+                //鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
+                if (!DBUtility.ClsPub.Security_Log("WW_EntrustProcessSendOutBill_Edit", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳潈闄愮紪杈�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 WebAPI.DLL.ClsWW_EntrustProcessSendOutBill Sendwork = new WebAPI.DLL.ClsWW_EntrustProcessSendOutBill();
                 List<WebAPI.Models.ClsWW_EntrustProcessSendOutBillMain> lsmain = new List<WebAPI.Models.ClsWW_EntrustProcessSendOutBillMain>();
                 msg2 = msg2.Replace("\\", "");
diff --git "a/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESBeginStepWorkBillController.cs" "b/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESBeginStepWorkBillController.cs"
index 3728b32..b980451 100644
--- "a/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESBeginStepWorkBillController.cs"
+++ "b/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESBeginStepWorkBillController.cs"
@@ -40,10 +40,19 @@
 
         [Route("Sc_MESBeginStepWorkBill/GetMESBeginStepWorkBill")]
         [HttpGet]
-        public object GetMESBeginStepWorkBill(string sWhere)
+        public object GetMESBeginStepWorkBill(string sWhere,string user)
         {
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("MES_MESBeginWorkBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳煡璇㈡潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
 
                 ds = Sc_GetMESBeginStepWorkBill(sWhere);
                 objJsonResult.code = "1";
@@ -107,7 +116,7 @@
         {
             DBUtility.ClsPub.CurUserName = UserName;
             //缂栬緫鏉冮檺
-            if (!DBUtility.ClsPub.Security_Log_second("MES_MESBeginWorkBill_Delete", 1, false, DBUtility.ClsPub.CurUserName))
+            if (!DBUtility.ClsPub.Security_Log_second("MES_MESBeginWorkBill_Drop", 1, false, DBUtility.ClsPub.CurUserName))
             {
                 objJsonResult.code = "0";
                 objJsonResult.count = 0;
diff --git "a/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESEndStepWorkBillController.cs" "b/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESEndStepWorkBillController.cs"
index d40c8e1..ee776bf 100644
--- "a/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESEndStepWorkBillController.cs"
+++ "b/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESEndStepWorkBillController.cs"
@@ -30,10 +30,19 @@
 
         [Route("Sc_MESEndStepWorkBill/GetMESEndWorkBill")]
         [HttpGet]
-        public object GetMESEndWorkBill(string sWhere)
+        public object GetMESEndWorkBill(string sWhere,string user)
         {
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("MES_MESEndWorkBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳煡璇㈡潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
 
                 ds = Sc_GetMESEndWorkBill(sWhere);
                 objJsonResult.code = "1";
@@ -200,7 +209,7 @@
         {
             DBUtility.ClsPub.CurUserName = UserName;
             //缂栬緫鏉冮檺
-            if (!DBUtility.ClsPub.Security_Log_second("MES_MESEndWorkBill_Delete", 1, false, DBUtility.ClsPub.CurUserName))
+            if (!DBUtility.ClsPub.Security_Log_second("MES_MESEndWorkBill_Drop", 1, false, DBUtility.ClsPub.CurUserName))
             {
                 objJsonResult.code = "0";
                 objJsonResult.count = 0;
diff --git "a/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESStopStepWorkBillController.cs" "b/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESStopStepWorkBillController.cs"
index ce63243..3c2fc28 100644
--- "a/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESStopStepWorkBillController.cs"
+++ "b/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MESStopStepWorkBillController.cs"
@@ -30,10 +30,20 @@
         #region 鍋滃伐鍗�(璧板伐搴�)鍒楄〃
         [Route("Sc_MESStopStepWorkBill/list")]
         [HttpGet]
-        public object list(string sWhere)
+        public object list(string sWhere,string user)
         {
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("MES_MESStopWorkBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳煡璇㈡潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (sWhere == null || sWhere.Equals(""))
                 {
                     ds = oCN.RunProcReturn("select * from h_v_Sc_MESStopWorkBillList_NEW " + sWhere, "h_v_Sc_MESStopWorkBillList_NEW");
@@ -192,7 +202,7 @@
         {
             DBUtility.ClsPub.CurUserName = UserName;
             //缂栬緫鏉冮檺
-            if (!DBUtility.ClsPub.Security_Log_second("MES_MESStopWorkBill_Delete", 1, false, DBUtility.ClsPub.CurUserName))
+            if (!DBUtility.ClsPub.Security_Log_second("MES_MESStopWorkBill_Drop", 1, false, DBUtility.ClsPub.CurUserName))
             {
                 objJsonResult.code = "0";
                 objJsonResult.count = 0;
diff --git "a/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MaterToSourceStepBillController.cs" "b/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MaterToSourceStepBillController.cs"
index ac9d7f8..48cff07 100644
--- "a/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MaterToSourceStepBillController.cs"
+++ "b/WebAPI/Controllers/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/Sc_MaterToSourceStepBillController.cs"
@@ -34,10 +34,20 @@
         /// </summary>
         [Route("Sc_MaterToSourceStepBill/list")]
         [HttpGet]
-        public object list(string sWhere)
+        public object list(string sWhere,string user)
         {
             try
             {
+                //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄�
+                if (!DBUtility.ClsPub.Security_Log("Sc_MaterToSourceStepBill_Query", 1, false, user))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳煡璇㈡潈闄�!";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (sWhere == null || sWhere.Equals(""))
                 {
                     ds = oCN.RunProcReturn("select * from h_v_Sc_MaterToSourceBillMain " + sWhere, "h_v_Sc_MaterToSourceBillMain");
@@ -146,14 +156,14 @@
         {
             DBUtility.ClsPub.CurUserName = UserName;
             //缂栬緫鏉冮檺
-            //if (!DBUtility.ClsPub.Security_Log("MES_MaterToSourceBill_Delete", 1, false, DBUtility.ClsPub.CurUserName))
-            //{
-            //    objJsonResult.code = "0";
-            //    objJsonResult.count = 0;
-            //    objJsonResult.Message = "鏃犲垹闄ゆ潈闄愶紒";
-            //    objJsonResult.data = null;
-            //    return objJsonResult;
-            //}
+            if (!DBUtility.ClsPub.Security_Log("Sc_MaterToSourceStepBill_Drop", 1, false, DBUtility.ClsPub.CurUserName))
+            {
+                objJsonResult.code = "0";
+                objJsonResult.count = 0;
+                objJsonResult.Message = "鏃犲垹闄ゆ潈闄愶紒";
+                objJsonResult.data = null;
+                return objJsonResult;
+            }
 
 
             Int64 lngBillKey = 0;
@@ -417,16 +427,17 @@
             string msg2 = sArray[0].ToString();
             string msg3 = sArray[1].ToString();
             string refSav = sArray[2].ToString();
+            string user = sArray[3].ToString();
 
             //淇濆瓨鏉冮檺
-            //if (!DBUtility.ClsPub.Security_Log("MES_MaterToSourceBill_Edit", 1, false, DBUtility.ClsPub.CurUserName))
-            //{
-            //    objJsonResult.code = "0";
-            //    objJsonResult.count = 0;
-            //    objJsonResult.Message = "鏃犱繚瀛樻潈闄愶紒";
-            //    objJsonResult.data = null;
-            //    return objJsonResult;
-            //}
+            if (!DBUtility.ClsPub.Security_Log("Sc_MaterToSourceStepBill_Edit", 1, false, user))
+            {
+                objJsonResult.code = "0";
+                objJsonResult.count = 0;
+                objJsonResult.Message = "鏃犱繚瀛樻潈闄愶紒";
+                objJsonResult.data = null;
+                return objJsonResult;
+            }
 
             //鍒ゆ柇浼氳鏈熸槸鍚﹀悎鐞�
             string s = "";
@@ -640,19 +651,20 @@
         [HttpGet]
         public object AuditProcessReportList(int HInterID, int IsAudit, string CurUserName)
         {
-            string ModRightNameCheck = "MES_MaterToSourceBill_Check";
+            string ModRightNameCheck = "Sc_MaterToSourceStepBill_Check";
             DBUtility.ClsPub.CurUserName = CurUserName;
             try
             {
                 //瀹℃牳鏉冮檺
-                //if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
-                //{
-                //    objJsonResult.code = "0";
-                //    objJsonResult.count = 0;
-                //    objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�";
-                //    objJsonResult.data = null;
-                //    return objJsonResult;
-                //}
+                if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, false, CurUserName))
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (HInterID <= 0)
                 {
                     objJsonResult.code = "0";
diff --git a/WebAPI/WebAPI.csproj b/WebAPI/WebAPI.csproj
index c9ba6e0..604c105 100644
--- a/WebAPI/WebAPI.csproj
+++ b/WebAPI/WebAPI.csproj
@@ -354,6 +354,7 @@
     <Compile Include="Controllers\CJGL\Cj_StationOutBillController.cs" />
     <Compile Include="Controllers\CJGL\Cj_StationInBillController.cs" />
     <Compile Include="Controllers\CJGL\Cj_StationEntrustOutBillController.cs" />
+    <Compile Include="Controllers\SCGL\Sc_ICBomBillController.cs" />
     <Compile Include="Controllers\Sc_PckSplitBillController.cs" />
     <Compile Include="Controllers\GZGL\Gy_DuSubsidyItemBillController.cs" />
     <Compile Include="Controllers\GZGL\Gy_WorkPayTypeBillController.cs" />
@@ -769,6 +770,7 @@
     <Folder Include="obj\x86\Debug\" />
     <Folder Include="Views\Cg_PurchaseReturn\" />
     <Folder Include="Views\Gy_EquipType\" />
+    <Folder Include="Views\Gy_ICBomBill\" />
     <Folder Include="Views\Gy_RoutingGroup\" />
     <Folder Include="Views\KF_ICInventoryList_WMSBill\" />
     <Folder Include="Views\Kf_ICStockBillMain\" />

--
Gitblit v1.9.1