From 2609bffee3a8de0d1e08b1b2c3fa3cfe13064f4e Mon Sep 17 00:00:00 2001
From: duhe <226547893@qq.com>
Date: 星期一, 24 三月 2025 11:40:14 +0800
Subject: [PATCH] 1
---
WebAPI/Controllers/BaseSet/Gy_GroupController.cs | 402 ++++++++++++++++++++++++++++++++++++++++++++++++++++++--
1 files changed, 383 insertions(+), 19 deletions(-)
diff --git a/WebAPI/Controllers/BaseSet/Gy_GroupController.cs b/WebAPI/Controllers/BaseSet/Gy_GroupController.cs
index 621dab5..154c737 100644
--- a/WebAPI/Controllers/BaseSet/Gy_GroupController.cs
+++ b/WebAPI/Controllers/BaseSet/Gy_GroupController.cs
@@ -27,8 +27,6 @@
/// <summary>
/// 杩斿洖鐝粍鍒楄〃
- ///鍙傛暟锛歴tring sql銆�
- ///杩斿洖鍊硷細object銆�
/// </summary>
[Route("Gy_Group/list")]
[HttpGet]
@@ -276,8 +274,6 @@
string[] sArray = msg1.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries);
string msg2 = sArray[0].ToString();
string user = sArray[1].ToString();//鐢ㄦ埛鍚�
- //string msg4 = sArray[2].ToString();
- //string msg5 = sArray[3].ToString();
//鍒ゆ柇鏄惁鏈夌紪杈戞潈闄�
if (!DBUtility.ClsPub.Security_Log("Gy_Group_Edit", 1, false, user))
@@ -311,9 +307,15 @@
string HCompName = list[0].HCompName;
string HPayMentType = list[0].HPayMentType;
var HDeptNumber = "";
- //var HEndFlag = 0;
long HLevel = 1;
- //var HProcID = "";
+ string HMakeEmp = list[0].HMakeEmp;
+ string HCheckEmp = list[0].HCheckEmp;
+ string HCheckTime = list[0].HCheckTime;
+ string HModifyEmp = list[0].HModifyEmp;
+ string HModifyTime = list[0].HModifyTime;
+ string HStopEmp = list[0].HStopEmp;
+ string HStopTime = list[0].HStopTime;
+ long HCREATEORGID = list[0].HCREATEORGID;
//鍒ゆ柇鏉冮檺
//if (!ClsPub.Security_Log(msg5, 1, false, msg4))
@@ -347,22 +349,101 @@
if (HItemID == 0)
{
oCN.BeginTran();
+
+ //淇濆瓨鍓嶆帶鍒�=========================================
+ string sql1 = "exec h_p_Gy_Group_BeforeSaveCtrl " + HMakeEmp + ",'" + 1 + "'";
+ ds = oCN.RunProcReturn(sql1, "h_p_Gy_Group_BeforeSaveCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "淇濆瓨澶辫触!鍘熷洜:淇濆瓨鍓嶅垽鏂け璐ワ紝璇蜂笌缃戠粶绠$悊浜哄憳鑱旂郴";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "淇濆瓨澶辫触!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
+
oCN.RunProc("Insert into Gy_Group " +
" (HNumber,HName,HHelpCode,HShortNumber,HParentID" +
- ",HEmpQty,HDeptID,HDeptNumber,HProcID" +
- ",HLevel,HEndFlag,HStopflag,HRemark,HBarCodeForBase,HUSEORGID,HCompName,HPayMentType,HMakeEmp,HMakeTime) " +
- " Values('" + HNumber + "','" + HName + "','" + HHelpCode + "','" + HShortNumber + "'," + HParentID.ToString() +
- "," + HEmpQty.ToString() + "," + HDeptID.ToString() + ",'" + HDeptNumber + "'," + HProcID.ToString() +
- "," + HLevel.ToString() + "," + Convert.ToString(HEndFlag ? 1 : 0) + "," + Convert.ToString(HStopflag ? 1 : 0) + ",'" + HRemark + "','" + HBarCodeForBase + "',"+ HUSEORGID + ",'" + HCompName +"','"+ HPayMentType + "','" + user + "',getdate())", ref DBUtility.ClsPub.sExeReturnInfo);
+ ",HEmpQty,HDeptID,HDeptNumber,HProcID,HUseFlag" +
+ ",HLevel,HEndFlag,HStopflag,HRemark,HBarCodeForBase," +
+ "HUSEORGID,HCREATEORGID,HCompName,HPayMentType,HMakeEmp,HMakeTime) " +
+ " Values('" + HNumber + "','" + HName + "','" + HHelpCode + "','" + HShortNumber + "','" + HParentID.ToString() +
+ "','" + HEmpQty.ToString() + "','" + HDeptID.ToString() + "','" + HDeptNumber + "','" + HProcID.ToString() + "','" + HUseFlag.ToString() +
+ "','" + HLevel.ToString() + "'," + Convert.ToString(HEndFlag ? 1 : 0) + "," + Convert.ToString(HStopflag ? 1 : 0) + ",'" + HRemark + "','" + HBarCodeForBase + "'" +
+ ",'" + HUSEORGID + "','" + HCREATEORGID + "','" + HCompName + "','" + HPayMentType + "','" + user + "',getdate())", ref DBUtility.ClsPub.sExeReturnInfo);
//淇敼涓婄骇涓洪潪鏈骇浠g爜
oCN.RunProc("Update Gy_Group set HEndflag=0 where HItemID=" + HParentID, ref DBUtility.ClsPub.sExeReturnInfo);
+
+
+ //淇濆瓨鍚庢帶鍒�=========================================
+ string sql2 = "exec h_p_Gy_Group_AfterSaveCtrl " + HMakeEmp + ",'" + 1 + "'";
+ ds = oCN.RunProcReturn(sql2, "h_p_Gy_Group_AfterSaveCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "淇濆瓨澶辫触!鍘熷洜锛氫繚瀛樺悗鍒ゆ柇澶辫触锛岃涓庣綉缁滅鐞嗕汉鍛樿仈绯�";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "淇濆瓨澶辫触!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
oCN.Commit();
}
else
{
//鑻AINDI閲嶅鍒欓噸鏂拌幏鍙�
oCN.BeginTran();
- oCN.RunProc("Update Gy_Group set " +
+
+ //淇濆瓨鍓嶆帶鍒�=========================================
+ string sql1 = "exec h_p_Gy_Group_BeforeSaveCtrl " + HMakeEmp + ",'" + 2 + "'";
+ ds = oCN.RunProcReturn(sql1, "h_p_Gy_Group_BeforeSaveCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "淇濆瓨澶辫触!鍘熷洜:淇濆瓨鍓嶅垽鏂け璐ワ紝璇蜂笌缃戠粶绠$悊浜哄憳鑱旂郴";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "淇濆瓨澶辫触!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
+ oCN.RunProc("Update Gy_Group set " +
" HNumber='" + HNumber + "'" +
",HName='" + HName + "'" +
",HShortNumber='" + HShortNumber + "'" +
@@ -370,21 +451,50 @@
",HParentID=" + HParentID +
",HStopflag='" + HStopflag + "'" +
",HRemark= '" + HRemark + "'" +
+ ",HUseFlag= " + HUseFlag +
+ ",HUSEORGID='" + HUSEORGID + "'" +
+ ",HCREATEORGID='" + HCREATEORGID + "'" +
",HModifyEmp= '" + user + "'" +
",HModifyTime= getdate()" +
",HDeptID=" + HDeptID +
",HEmpQty=" + HEmpQty +
- ",HCompName='"+ HCompName+"'"+
+ ",HCompName='" + HCompName + "'" +
",HPayMentType='" + HPayMentType +
"',HBarCodeForBase='" + HBarCodeForBase + "' " +
", HProcID = '" + HProcID + "' Where HItemID=" + HItemID, ref DBUtility.ClsPub.sExeReturnInfo);
oCN.RunProc("Update Gy_Group set HEndflag=0 where HItemID=" + HParentID, ref DBUtility.ClsPub.sExeReturnInfo);
+
+
+ //淇濆瓨鍚庢帶鍒�=========================================
+ string sql2 = "exec h_p_Gy_Group_AfterSaveCtrl " + HMakeEmp + ",'" + 2 + "'";
+ ds = oCN.RunProcReturn(sql2, "h_p_Gy_Group_AfterSaveCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "淇濆瓨澶辫触!鍘熷洜锛氫繚瀛樺悗鍒ゆ柇澶辫触锛岃涓庣綉缁滅鐞嗕汉鍛樿仈绯�";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "淇濆瓨澶辫触!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
+
oCN.Commit();
}
objJsonResult.code = "0";
objJsonResult.count = 1;
objJsonResult.Message = "淇濆瓨鎴愬姛锛�";
- //WebAPIController.Add_Log("閫佽揣鍗曚笅鎺�", UserName, "鐢熸垚閫佽揣鍗�");
objJsonResult.data = 1;
return objJsonResult;
}
@@ -398,6 +508,8 @@
return objJsonResult;
}
}
+
+ #region
///// <summary>
///// 淇敼鍗曟嵁-淇濆瓨鎸夐挳
/////鍙傛暟锛歴tring sql銆�
@@ -492,6 +604,9 @@
// return objJsonResult;
// }
//}
+ #endregion
+
+
/// <summary>
/// 鐝粍鍒犻櫎鍔熻兘
/// </summary>
@@ -502,7 +617,6 @@
{
DataSet ds;
DataSet ds1;
- string ModRightNameCheck = "Gy_Group_Delete";
try
{
//鍒犻櫎鏉冮檺
@@ -572,7 +686,59 @@
return objJsonResult;
}
+ //鍒犻櫎鍓嶆帶鍒�=========================================
+ string sql1 = "exec h_p_Gy_Group_BeforeDelCtrl " + HItemID + ",'" + user + "'";
+ ds = oCN.RunProcReturn(sql1, "h_p_Gy_Group_BeforeDelCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍒犻櫎澶辫触!鍘熷洜:鍒犻櫎鍓嶅垽鏂け璐ワ紝璇蜂笌缃戠粶绠$悊浜哄憳鑱旂郴";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍒犻櫎澶辫触!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
+
oCN.RunProc("delete from Gy_Group where HItemID=" + HItemID);
+
+
+ //鍒犻櫎鍚庢帶鍒�=========================================
+ string sql2 = "exec h_p_Gy_Group_AfterDelCtrl " + HItemID + ",'" + user + "'";
+ ds = oCN.RunProcReturn(sql2, "h_p_Gy_Group_AfterDelCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍒犻櫎澶辫触!鍘熷洜锛氬垹闄ゅ悗鍒ゆ柇澶辫触锛岃涓庣綉缁滅鐞嗕汉鍛樿仈绯�";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍒犻櫎澶辫触!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
+
oCN.Commit();//鎻愪氦浜嬪姟
objJsonResult.code = "0";
objJsonResult.count = 1;
@@ -654,7 +820,57 @@
if (IsAudit == 0) //瀹℃牳鍒ゆ柇
{
+ //瀹℃牳鍓嶆帶鍒�=========================================
+ string sql1 = "exec h_p_Gy_Group_BeforeCheckCtrl " + HInterID + ",'" + CurUserName + "'";
+ ds = oCN.RunProcReturn(sql1, "h_p_Gy_Group_BeforeCheckCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "瀹℃牳澶辫触!鍘熷洜:瀹℃牳鍓嶅垽鏂け璐ワ紝璇蜂笌缃戠粶绠$悊浜哄憳鑱旂郴";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "瀹℃牳澶辫触!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
+
oCN.RunProc("update Gy_Group set HCheckEmp='" + CurUserName + "',HCheckTime=getdate() where HItemID=" + HInterID);
+
+ //瀹℃牳鍚庢帶鍒�=========================================
+ string sql2 = "exec h_p_Gy_Group_AfterCheckCtrl " + HInterID + ",'" + CurUserName + "'";
+ ds = oCN.RunProcReturn(sql2, "h_p_Gy_Group_AfterCheckCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "瀹℃牳澶辫触!鍘熷洜:瀹℃牳鍚庡垽鏂け璐ワ紝璇蜂笌缃戠粶绠$悊浜哄憳鑱旂郴";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "瀹℃牳澶辫触!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
objJsonResult.code = "1";
objJsonResult.count = 1;
@@ -663,7 +879,58 @@
}
if (IsAudit == 1) //鍙嶅鏍稿垽鏂�
{
+ //鍙嶅鏍稿墠鎺у埗=========================================
+ string sql1 = "exec h_p_Gy_Group_BeforeUnCheckCtrl " + HInterID + ",'" + CurUserName + "'";
+ ds = oCN.RunProcReturn(sql1, "h_p_Gy_Group_BeforeCheckCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍙嶅鏍稿け璐�!鍘熷洜:鍙嶅鏍稿墠鍒ゆ柇澶辫触锛岃涓庣綉缁滅鐞嗕汉鍛樿仈绯�";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍙嶅鏍稿け璐�!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
+
oCN.RunProc("update Gy_Group set HCheckEmp='',HCheckTime=null where HItemID=" + HInterID);
+
+
+ //鍙嶅鏍稿悗鎺у埗=========================================
+ string sql2 = "exec h_p_Gy_Group_AfterUnCheckCtrl " + HInterID + ",'" + CurUserName + "'";
+ ds = oCN.RunProcReturn(sql2, "h_p_Gy_Group_AfterCheckCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍙嶅鏍稿け璐�!鍘熷洜:鍙嶅鏍稿悗鍒ゆ柇澶辫触锛岃涓庣綉缁滅鐞嗕汉鍛樿仈绯�";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍙嶅鏍稿け璐�!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
objJsonResult.code = "1";
objJsonResult.count = 1;
@@ -749,7 +1016,55 @@
if (IsStop == 0) //绂佺敤鍒ゆ柇
{
+ //绂佺敤鍓嶆帶鍒�=========================================
+ string sql1 = "exec h_p_Gy_Group_BeforeStopCtrl " + HInterID + ",'" + CurUserName + "'";
+ ds = oCN.RunProcReturn(sql1, "h_p_Gy_Group_BeforeStopCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "绂佺敤澶辫触!鍘熷洜:绂佺敤鍓嶅垽鏂け璐ワ紝璇蜂笌缃戠粶绠$悊浜哄憳鑱旂郴";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "绂佺敤澶辫触!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
oCN.RunProc("update Gy_Group set HStopEmp='" + CurUserName + "',HStopTime=getdate(),HStopflag=1 where HItemID=" + HInterID);
+
+
+ //绂佺敤鍚庢帶鍒�=========================================
+ string sql2 = "exec h_p_Gy_Group_AfterStopCtrl " + HInterID + ",'" + CurUserName + "'";
+ ds = oCN.RunProcReturn(sql2, "h_p_Gy_Group_AfterStopCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "绂佺敤澶辫触!鍘熷洜:绂佺敤鍚庡垽鏂け璐ワ紝璇蜂笌缃戠粶绠$悊浜哄憳鑱旂郴";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "绂佺敤澶辫触!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
objJsonResult.code = "1";
objJsonResult.count = 1;
@@ -758,7 +1073,56 @@
}
if (IsStop == 1) //鍙嶇鐢ㄥ垽鏂�
{
+ //鍙嶇鐢ㄥ墠鎺у埗=========================================
+ string sql1 = "exec h_p_Gy_Group_BeforeUnStopCtrl " + HInterID + ",'" + CurUserName + "'";
+ ds = oCN.RunProcReturn(sql1, "h_p_Gy_Group_BeforeUnStopCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍙嶇鐢ㄥけ璐�!鍘熷洜:鍙嶇鐢ㄥ墠鍒ゆ柇澶辫触锛岃涓庣綉缁滅鐞嗕汉鍛樿仈绯�";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍙嶇鐢ㄥけ璐�!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
+
oCN.RunProc("update Gy_Group set HStopEmp='',HStopTime=null,HStopflag=0 where HItemID=" + HInterID);
+
+
+ //鍙嶇鐢ㄥ悗鎺у埗=========================================
+ string sql2 = "exec h_p_Gy_Group_AfterUnStopCtrl " + HInterID + ",'" + CurUserName + "'";
+ ds = oCN.RunProcReturn(sql2, "h_p_Gy_Group_AfterUnStopCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍙嶇鐢ㄥけ璐�!鍘熷洜:鍙嶇鐢ㄥ悗鍒ゆ柇澶辫触锛岃涓庣綉缁滅鐞嗕汉鍛樿仈绯�";
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍙嶇鐢ㄥけ璐�!鍘熷洜:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==================================================================================
objJsonResult.code = "1";
objJsonResult.count = 1;
@@ -782,9 +1146,9 @@
#endregion
#region 鐢熶骇鐝粍 鏂囦欢涓婁紶
- [Route("Gy_Group/Gy_Process_Excel")]
+ [Route("Gy_Group/Gy_Group_Excel")]
[HttpPost]
- public json Gy_Process_Excel()
+ public json Gy_Group_Excel()
{
json res = new json();
try
@@ -983,8 +1347,8 @@
}
#endregion
- #region 宸ュ簭椤圭洰 瀵煎叆(淇濆瓨)
- [Route("Gy_Group/Gy_Process_btnSave")]
+ #region 鐢熶骇鐝粍 瀵煎叆(淇濆瓨)
+ [Route("Gy_Group/Gy_Group_btnSave")]
[HttpPost]
public object Gy_Group_btnSave([FromBody] JObject sMainSub)
{
--
Gitblit v1.9.1