From c4c02944532a9bfda6de9a0cd85a9dfa631ed003 Mon Sep 17 00:00:00 2001
From: zrg <z18737863051@163.com>
Date: 星期六, 17 五月 2025 15:28:19 +0800
Subject: [PATCH] 1

---
 WebAPI/Controllers/BaseSet/Gy_MaterialController.cs |   83 +++++++++++++++++++++++++++++++----------
 1 files changed, 63 insertions(+), 20 deletions(-)

diff --git a/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs b/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
index 15da306..caeec5c 100644
--- a/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
+++ b/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
@@ -570,6 +570,7 @@
                     oItem.HShortNumber = sShortNumber;//鐭唬鐮�
                     oItem.HEndFlag = true;//鏈骇鏍囧織
                     oItem.HLevel = DBUtility.ClsPub.GetLevel(oItem.HNumber.Trim()); //绛夌骇
+                    oItem.HMakeEmp = msg2;
                     oBill.oModel = oItem;
                 }
                 //淇濆瓨
@@ -1120,11 +1121,11 @@
         [HttpGet]
         public object DeltetGy_Material(string HItemID, string user)
         {
+            SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
+            oCN.BeginTran();//寮�濮嬩簨鍔�
             DataSet ds;
             try
             {
-                SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
-
                 if (user == "10000")//api鍚屾鏂瑰紡
                 {
                     oCN.RunProc("delete from Gy_Material where HERPItemID=" + HItemID);
@@ -1152,7 +1153,7 @@
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
-                oCN.BeginTran();//寮�濮嬩簨鍔�
+                
                 ds = oCN.RunProcReturn("select * from Gy_Material where HItemID=" + HItemID, "Gy_Material");
                 if (ds == null || ds.Tables[0].Rows.Count == 0)
                 {
@@ -1386,7 +1387,49 @@
         }
         #endregion
 
+        #region 鑾峰彇褰撳墠鍏徃鍚�
+        /// <summary>
+        /// 
+        /// </summary>
+        /// <param name="HInterID">鍗曟嵁ID</param>
+        /// <param name="IsAudit">瀹℃牳(0),鍙嶅鏍�(1)</param>
+        /// <param name="CurUserName">瀹℃牳浜�</param>
+        /// <returns></returns>
+        [Route("Xt_getInfo/getCompanyName")]
+        [HttpGet]
+        public object getCompanyName()
+        {
+            try
+            {
+                string sErr = "";
+                if(oSystemParameter.ShowBill(ref sErr))
+                {
+                    objJsonResult.code = "1";
+                    objJsonResult.count = 1;
+                    objJsonResult.Message = oSystemParameter.omodel.WMS_CampanyName;
+                    objJsonResult.data = oSystemParameter.omodel.WMS_CampanyName;
+                }
+                else
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "褰撳墠鍏徃鍚嶈幏鍙栧け璐ワ紒" ;
+                    objJsonResult.data = null;
+                }
 
+                return objJsonResult;
+            }
+            catch (Exception e)
+            {
+                oCN.RollBack();
+                objJsonResult.code = "0";
+                objJsonResult.count = 0;
+                objJsonResult.Message = e.ToString();
+                objJsonResult.data = null;
+                return objJsonResult;
+            }
+        }
+        #endregion
 
 
         /// <summary>
@@ -1705,7 +1748,7 @@
                 {
                     objJsonResult.code = "0";
                     objJsonResult.count = 0;
-                    objJsonResult.Message = "鏃犲垹闄ゆ潈闄愶紒";
+                    objJsonResult.Message = "[0000-1-058]鏃犲垹闄ゆ潈闄愶紒";
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
@@ -1716,7 +1759,7 @@
                 {
                     objJsonResult.code = "0";
                     objJsonResult.count = 0;
-                    objJsonResult.Message = "鍒犻櫎鏉$爜鍓嶅垽鏂彂鐢熼敊璇紒";
+                    objJsonResult.Message = "[3899-1-001]鍒犻櫎鏉$爜鍓嶅垽鏂彂鐢熼敊璇紒";
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
@@ -1726,9 +1769,9 @@
                     {
                         objJsonResult.code = "0";
                         objJsonResult.count = 0;
-                        objJsonResult.Message = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HRemark"]);
+                        objJsonResult.Message = "[0000-1-007]" + DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HRemark"]);
                         objJsonResult.data = null;
-                        return objJsonResult;                       
+                        return objJsonResult;
                     }
                 }
                 //Int64 lngBillKey = 0;
@@ -1737,7 +1780,7 @@
                 {
                     objJsonResult.code = "0";
                     objJsonResult.count = 0;
-                    objJsonResult.Message = "鍗曟嵁ID涓虹┖锛�";
+                    objJsonResult.Message = "[0000-1-009]鍗曟嵁ID涓虹┖锛�";
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
@@ -1782,7 +1825,7 @@
                     oCN.Commit();
                     objJsonResult.code = "1";
                     objJsonResult.count = 1;
-                    objJsonResult.Message = "鍒犻櫎鎴愬姛";
+                    objJsonResult.Message = "[0000-1-008]鍒犻櫎鎴愬姛";
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
@@ -1790,7 +1833,7 @@
                 {
                     objJsonResult.code = "0";
                     objJsonResult.count = 0;
-                    objJsonResult.Message = "鍗曟嵁鏈壘鍒�";
+                    objJsonResult.Message = "[0000-1-045]鍗曟嵁鏈壘鍒�";
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
@@ -1800,7 +1843,7 @@
                 oCN.RollBack();
                 objJsonResult.code = "0";
                 objJsonResult.count = 0;
-                objJsonResult.Message = e.Message;
+                objJsonResult.Message = "[0000-1-007]" + e.Message;
                 objJsonResult.data = null;
                 return objJsonResult;
             }
@@ -1827,7 +1870,7 @@
                 {
                     objJsonResult.code = "0";
                     objJsonResult.count = 0;
-                    objJsonResult.Message = "浣滃簾澶辫触锛佹棤鏉冮檺锛�";
+                    objJsonResult.Message = "[0000-1-063]浣滃簾澶辫触锛佹棤鏉冮檺锛�";
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
@@ -1836,7 +1879,7 @@
                 {
                     objJsonResult.code = "0";
                     objJsonResult.count = 0;
-                    objJsonResult.Message = "HInterID灏忎簬0锛�";
+                    objJsonResult.Message = "[0000-1-009]HInterID灏忎簬0锛�";
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
@@ -1864,7 +1907,7 @@
 
                         objJsonResult.code = "1";
                         objJsonResult.count = 1;
-                        objJsonResult.Message = "浣滃簾鎴愬姛";
+                        objJsonResult.Message = "[0000-1-040]浣滃簾鎴愬姛";
                         objJsonResult.data = null;
 
                         oCN.Commit();
@@ -1873,7 +1916,7 @@
                     {
                         objJsonResult.code = "0";
                         objJsonResult.count = 0;
-                        objJsonResult.Message = "浣滃簾澶辫触!鍘熷洜:" + DBUtility.ClsPub.sExeReturnInfo;
+                        objJsonResult.Message = "[0000-1-042]浣滃簾澶辫触!鍘熷洜:" + DBUtility.ClsPub.sExeReturnInfo;
                         objJsonResult.data = null;
 
                         oCN.RollBack();
@@ -1896,7 +1939,7 @@
 
                         objJsonResult.code = "0";
                         objJsonResult.count = 0;
-                        objJsonResult.Message = "鍙嶄綔搴熷け璐ワ紝鍘熷洜锛氬弽浣滃簾鏉$爜鍓嶅垽鏂彂鐢熼敊璇紒";
+                        objJsonResult.Message = "[0000-1-042]鍙嶄綔搴熷け璐ワ紝鍘熷洜锛氬弽浣滃簾鏉$爜鍓嶅垽鏂彂鐢熼敊璇紒";
                         objJsonResult.data = null;
                         return objJsonResult;
                     }
@@ -1908,7 +1951,7 @@
 
                             objJsonResult.code = "1";
                             objJsonResult.count = 1;
-                            objJsonResult.Message = "鍙嶄綔搴熷け璐ワ紝鍘熷洜锛�" + DBUtility.ClsPub.isStrNull(DS.Tables[0].Rows[0]["HRemark"]);
+                            objJsonResult.Message = "[0000-1-042]鍙嶄綔搴熷け璐ワ紝鍘熷洜锛�" + DBUtility.ClsPub.isStrNull(DS.Tables[0].Rows[0]["HRemark"]);
                             objJsonResult.data = null;
                             return objJsonResult;
                         }
@@ -1930,7 +1973,7 @@
 
                         objJsonResult.code = "1";
                         objJsonResult.count = 1;
-                        objJsonResult.Message = "鍙嶄綔搴熸垚鍔�";
+                        objJsonResult.Message = "[0000-1-043]鍙嶄綔搴熸垚鍔�";
                         objJsonResult.data = null;
                         oCN.Commit();
                         return objJsonResult;
@@ -1939,7 +1982,7 @@
                     {
                         objJsonResult.code = "0";
                         objJsonResult.count = 0;
-                        objJsonResult.Message = "鍙嶄綔搴熷け璐�!鍘熷洜:" + DBUtility.ClsPub.sExeReturnInfo;
+                        objJsonResult.Message = "[0000-1-042]鍙嶄綔搴熷け璐�!鍘熷洜:" + DBUtility.ClsPub.sExeReturnInfo;
                         objJsonResult.data = null;
                         oCN.RollBack();
                         return objJsonResult;
@@ -1952,7 +1995,7 @@
                 oCN.RollBack();
                 objJsonResult.code = "0";
                 objJsonResult.count = 0;
-                objJsonResult.Message = "浣滃簾澶辫触鎴栬�呭弽浣滃簾澶辫触锛�" + e.ToString();
+                objJsonResult.Message = "[0000-1-044]浣滃簾澶辫触鎴栬�呭弽浣滃簾澶辫触锛�" + e.ToString();
                 objJsonResult.data = null;
                 return objJsonResult;
             }

--
Gitblit v1.9.1