From 3f26ee39e589ba9adfe63c99acd99d427ef80a85 Mon Sep 17 00:00:00 2001
From: zrg <z18737863051@163.com>
Date: 星期三, 23 十月 2024 09:07:36 +0800
Subject: [PATCH] 1
---
WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs | 111 ++++++++++++++++++++++++++++++++++++++++++++++++++++++-
1 files changed, 109 insertions(+), 2 deletions(-)
diff --git a/WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs b/WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs
index c9946f8..2d3d0fb 100644
--- a/WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs
+++ b/WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs
@@ -375,7 +375,7 @@
if (HStandard)
{
//璁剧疆榛樿宸ヨ壓璺嚎
- oCN.RunProc("exec h_p_Gy_RoutingBillCheck " + HInterID); //璁剧疆榛樿宸ヨ壓璺嚎
+ oCN.RunProc("exec h_p_Gy_RoutingBillCheck " + HInterID + ",'" + user + "'");
}
//鍒ゆ柇鏄惁閲嶅宸ュ簭鍙�
@@ -1646,6 +1646,20 @@
Int64 lngBillKey = 0;
lngBillKey = DBUtility.ClsPub.isLong(HInterID); //瀵笻InterID杩涜绫诲瀷鐨勮浆鎹�
DAL.ClsGy_RoutingBill oBill = new DAL.ClsGy_RoutingBill(); //瀹炰緥鍖栧崟鎹搷浣滅被锛岀敤浜庤繘琛岀浉鍏虫搷浣�
+ //鑾峰彇绯荤粺鍙傛暟鍒ゆ柇宸ヨ壓璺嚎鏄惁鍚敤澶氱骇瀹℃壒绂佺敤
+ Pub_Class.ClsXt_SystemParameter oSystemParameter = new Pub_Class.ClsXt_SystemParameter();
+ string sReturn = "";
+ if (oSystemParameter.ShowBill(ref sReturn) == true)
+ {
+ if (oSystemParameter.omodel.Gy_RoutingBill_EnableMultiLevel.ToUpper() == "N") //绯荤粺鍙傛暟 鏈惎鐢ㄨ嚜鍔ㄥ鏍�
+ {
+ objJsonResult.code = CodeConstant.FAIL;
+ objJsonResult.count = CountConstant.FAIL;
+ objJsonResult.Message = "宸ヨ壓璺嚎鏈惎鐢ㄥ绾у鎵圭鐢�";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo)) //鏍规嵁HInterID鑾峰彇璇ュ崟鎹殑鏁版嵁
{
if (oBill.omodel.HBillStatus != 6)
@@ -1713,6 +1727,21 @@
// objJsonResult.data = null;
// return objJsonResult;
//}
+
+ //鑾峰彇绯荤粺鍙傛暟鍒ゆ柇宸ヨ壓璺嚎鏄惁鍚敤澶氱骇瀹℃壒绂佺敤
+ Pub_Class.ClsXt_SystemParameter oSystemParameter = new Pub_Class.ClsXt_SystemParameter();
+ string sReturn = "";
+ if (oSystemParameter.ShowBill(ref sReturn) == true)
+ {
+ if (oSystemParameter.omodel.Gy_RoutingBill_EnableMultiLevel.ToUpper() == "N") //绯荤粺鍙傛暟 鏈惎鐢ㄨ嚜鍔ㄥ鏍�
+ {
+ objJsonResult.code = CodeConstant.FAIL;
+ objJsonResult.count = CountConstant.FAIL;
+ objJsonResult.Message = "宸ヨ壓璺嚎鏈惎鐢ㄥ绾у鎵圭鐢�";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
//HInterID鏁版嵁鍒ゆ柇
if (HInterID <= 0)
@@ -1782,7 +1811,20 @@
// objJsonResult.data = null;
// return objJsonResult;
//}
-
+ //鑾峰彇绯荤粺鍙傛暟鍒ゆ柇宸ヨ壓璺嚎鏄惁鍚敤澶氱骇瀹℃壒绂佺敤
+ Pub_Class.ClsXt_SystemParameter oSystemParameter = new Pub_Class.ClsXt_SystemParameter();
+ string sReturn = "";
+ if (oSystemParameter.ShowBill(ref sReturn) == true)
+ {
+ if (oSystemParameter.omodel.Gy_RoutingBill_EnableMultiLevel.ToUpper() == "N") //绯荤粺鍙傛暟 鏈惎鐢ㄨ嚜鍔ㄥ鏍�
+ {
+ objJsonResult.code = CodeConstant.FAIL;
+ objJsonResult.count = CountConstant.FAIL;
+ objJsonResult.Message = "宸ヨ壓璺嚎鏈惎鐢ㄥ绾у鎵圭鐢�";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
//HInterID鏁版嵁鍒ゆ柇
if (HInterID <= 0)
@@ -2152,5 +2194,70 @@
}
#endregion
+ #region 宸ヨ壓璺嚎 鍏抽棴鍏跺畠鍗曟嵁
+ [Route("Gy_Routing/CloseOther")]
+ [HttpGet]
+ public object CloseOther(int HInterID, string CurUserName)
+ {
+ DBUtility.ClsPub.CurUserName = CurUserName;
+ try
+ {
+ //鍒ゆ柇鏄惁鏈夊叧闂叾瀹冩潈闄�
+ if (!DBUtility.ClsPub.Security_Log("Gy_RoutingBill_CloseOther", 1, false, CurUserName))
+ {
+ objJsonResult.code = CodeConstant.FAIL;
+ objJsonResult.count = CountConstant.FAIL;
+ objJsonResult.Message = "宸ヨ壓璺嚎鏃犳潈闄愬叧闂叾瀹冨崟鎹�!";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+
+ oCN.BeginTran();//寮�濮嬩簨鍔�
+
+ //鍒ゆ柇鍗曟嵁鏄惁瀛樺湪
+ DataSet ds;
+ string sql = "select * from Gy_RoutingBillMain where HinterID = " + HInterID;
+ ds = oCN.RunProcReturn(sql, "Gy_RoutingBillMain");
+ if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0)
+ {
+ //if (!(ds.Tables[0].Rows[0]["HChecker"] != null && ds.Tables[0].Rows[0]["HChecker"].ToString() != ""))
+ //{
+ // objJsonResult.code = "0";
+ // objJsonResult.count = 0;
+ // objJsonResult.Message = "鍗曟嵁鏈鏍�!涓嶅彲浠ヨ鍚敤涓鸿鐗╂枡鐨勯粯璁ゅ伐鑹鸿矾绾�!";
+ // objJsonResult.data = null;
+ // return objJsonResult;
+ //}
+ }
+ else
+ {
+ objJsonResult.code = CodeConstant.FAIL;
+ objJsonResult.count = CountConstant.FAIL;
+ objJsonResult.Message = "鍗曟嵁涓嶅瓨鍦紝妫�鏌ヨ鍗曟嵁鏄惁宸茬粡琚垹闄�!";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+
+ //鍒锋柊榛樿宸ヨ壓璺嚎
+ oCN.RunProc("exec h_p_Gy_RoutingBillClose " + HInterID + ",'" + CurUserName + "'");
+
+ oCN.Commit();//鎻愪氦浜嬪姟
+ objJsonResult.code = CodeConstant.SUCCEED;
+ objJsonResult.count = CountConstant.SUCCEED;
+ objJsonResult.Message = "鎵ц鎴愬姛锛�";
+ objJsonResult.data = null;
+ return objJsonResult; ;
+ }
+ catch (Exception e)
+ {
+ objJsonResult.code = CodeConstant.FAIL;
+ objJsonResult.count = CountConstant.FAIL;
+ objJsonResult.Message = "鍏抽棴鍏跺畠澶辫触澶辫触锛�" + e.ToString();
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
+ #endregion
+
}
}
\ No newline at end of file
--
Gitblit v1.9.1