From cee055eb7cdecf5d995cc65d379494e471bde9c8 Mon Sep 17 00:00:00 2001
From: yangle <admin@YINMOU>
Date: 星期三, 02 四月 2025 10:06:03 +0800
Subject: [PATCH] 合并
---
WebAPI/Controllers/CJGL/Cj_StationInBillController.cs | 74 ++++++++++++++++++++++++++++++-------
1 files changed, 60 insertions(+), 14 deletions(-)
diff --git a/WebAPI/Controllers/CJGL/Cj_StationInBillController.cs b/WebAPI/Controllers/CJGL/Cj_StationInBillController.cs
index 6f67eec..3f10ece 100644
--- a/WebAPI/Controllers/CJGL/Cj_StationInBillController.cs
+++ b/WebAPI/Controllers/CJGL/Cj_StationInBillController.cs
@@ -389,7 +389,7 @@
}
- //=========================淇濆瓨鍚庢帶鍒�
+ //=========================淇濆瓨鍚庢帶鍒� ============================
DataSet ds2 = oCN.RunProcReturn("Exec h_p_Sc_StationInBill_AfterSaveCtrl " + HInterID.ToString() + ", '" + HBillNo + "',1 ", "h_p_Sc_StationInBill_AfterSaveCtrl");
if (ds2 == null)
{
@@ -410,7 +410,7 @@
objJsonResult.data = null;
return objJsonResult;
}
- //============================
+ //=======================================================
oCN.Commit();
@@ -990,8 +990,6 @@
{
try
{
- string ModRightNameCheck = "";
-
if (HBillSubType == "SUB")
{
//瀹℃牳鏉冮檺
@@ -1046,7 +1044,7 @@
return objJsonResult;
}
- //瀹℃牳鍓嶆帶鍒�
+ //瀹℃牳鍓嶆帶鍒�==========================================================================
string HBillNo = oBill.omodel.HBillNo;
string sql = "exec h_p_Sc_StationInBill_BeforeCheckCtrl " + HInterID + ",'" + HBillNo + "','" + CurUserName + "'";
ds = oCN.RunProcReturn(sql, "h_p_Sc_StationInBill_BeforeCheckCtrl");
@@ -1067,7 +1065,7 @@
objJsonResult.data = null;
return objJsonResult;
}
-
+ //=============================================================================
//瀹℃牳
if (Cj_StationInBillCheckBill(HInterID, HBillNo, CurUserName, ref DBUtility.ClsPub.sExeReturnInfo))
{
@@ -1127,7 +1125,7 @@
{
}
- //瀹℃牳鍚庢帶鍒�
+ //瀹℃牳鍚庢帶鍒�=======================================================
string sql = "exec h_p_Sc_StationInBill_AfterCheckCtrl " + lngBillKey + ",'" + HBillNo + "','" + CurUserName + "'";
ds = oCN.RunProcReturn(sql, "h_p_Sc_StationInBill_AfterCheckCtrl");
if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
@@ -1142,7 +1140,7 @@
oCN.RollBack();
return false;
}
-
+ //====================================================================
sReturn = sReturn + " 瀹℃牳鍔熻兘锛�";
oCN.Commit();
return true;
@@ -1220,7 +1218,7 @@
return objJsonResult;
}
- //鍙嶅鏍稿墠鎺у埗
+ //鍙嶅鏍稿墠鎺у埗=============================================================================
string HBillNo = oBill.omodel.HBillNo;
string sql = "exec h_p_Sc_StationInBill_BeforeUnCheckCtrl " + HInterID + ",'" + HBillNo + "','" + CurUserName + "'";
ds = oCN.RunProcReturn(sql, "h_p_Sc_StationInBill_BeforeUnCheckCtrl");
@@ -1241,7 +1239,7 @@
objJsonResult.data = null;
return objJsonResult;
}
-
+ //============================================================================================
//鍙嶅鏍�
if (Cj_StationInBillAbandonCheckBill(HInterID, HBillNo, CurUserName, ref DBUtility.ClsPub.sExeReturnInfo))
{
@@ -1305,7 +1303,7 @@
{
}
- //鍙嶅鏍稿悗鎺у埗
+ //鍙嶅鏍稿悗鎺у埗========================================================================
string sql = "exec h_p_Sc_StationInBill_AfterUnCheckCtrl " + lngBillKey + ",'" + HBillNo + "','" + CurUserName + "'";
ds = oCN.RunProcReturn(sql, "h_p_Sc_StationInBill_AfterUnCheckCtrl");
if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
@@ -1320,7 +1318,7 @@
oCN.RollBack();
return false;
}
-
+ //============================================================================================
sReturn = sReturn + "鍙嶅鏍稿姛鑳斤紒";
oCN.Commit();
return true;
@@ -1420,8 +1418,32 @@
return objJsonResult;
}
}
+ var HBillNo = ds.Tables[0].Rows[0]["HBillNo"].ToString();
+
+ //鍏抽棴鍓嶆帶鍒�=========================================
+ string sql1 = "exec h_p_Sc_ShiftsBeginInfoBill_BeforeCloseCtrl " + HInterID + ",'" +HBillNo + "','" + user + "'";
+ ds = oCN.RunProcReturn(sql1, "h_p_Sc_ShiftsBeginInfoBill_BeforeCloseCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍏抽棴澶辫触!鍘熷洜:鍏抽棴鍓嶅垽鏂け璐ワ紝璇蜂笌缃戠粶绠$悊浜哄憳鑱旂郴";
+ objJsonResult.data = null;
+ 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;
+ return objJsonResult;
+ }
+ //==================================================================================
+
//鍏抽棴鍗曟嵁
- if (!BillOld.CloseBill(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo))
+ if (!BillOld.CloseBill(Int64.Parse(HInterID), HBillNo, "h_p_Sc_ShiftsBeginInfoBill_AfterCloseCtrl", user,ref ClsPub.sExeReturnInfo))
{
objJsonResult.code = "0";
objJsonResult.count = 1;
@@ -1447,8 +1469,32 @@
return objJsonResult;
}
}
+ var HBillNo = ds.Tables[0].Rows[0]["HBillNo"].ToString();
+ //鍙嶅叧闂墠鎺у埗=========================================
+ string sql1 = "exec h_p_Sc_StationInBill_BeforeUnCloseCtrl " + HInterID + ",'" + HBillNo + "','" + user + "'";
+ ds = oCN.RunProcReturn(sql1, "h_p_Sc_StationInBill_BeforeUnCloseCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍙嶅叧闂け璐�!鍘熷洜:鍙嶅叧闂墠鍒ゆ柇澶辫触锛岃涓庣綉缁滅鐞嗕汉鍛樿仈绯�";
+ objJsonResult.data = null;
+ 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;
+ return objJsonResult;
+ }
+ //==================================================================================
+
+
//鍙嶅叧闂崟鎹�
- if (!BillOld.CancelClose(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo))
+ if (!BillOld.CancelClose(Int64.Parse(HInterID), HBillNo, "h_p_Sc_StationInBill_AfterUnCloseCtrl", user, ref ClsPub.sExeReturnInfo))
{
objJsonResult.code = "0";
objJsonResult.count = 1;
--
Gitblit v1.9.1