From d36ee02a8062d81006324ac3f2170cb1c45e3359 Mon Sep 17 00:00:00 2001
From: zrg <z18737863051@163.com>
Date: 星期四, 25 四月 2024 17:12:50 +0800
Subject: [PATCH] 1.以下基础资料 测试并完善功能; 供应商,职员,物料,客户,班组 (测试必录项目,新增,修改,删除,审核,反审核 等功能,有图片预览的 完善图片预览以及上传功能) 2.客户 增加字段 领用人 HMateOutEmp varchar(100) 生产班组 增加 字段 劳务单位 HCompName varchar(200)
---
WebAPI/Controllers/CGGL/YF_PayMentBillController.cs | 63 +++++++++++++++++++++++++++++++
1 files changed, 62 insertions(+), 1 deletions(-)
diff --git a/WebAPI/Controllers/CGGL/YF_PayMentBillController.cs b/WebAPI/Controllers/CGGL/YF_PayMentBillController.cs
index 1280d07..afdbebb 100644
--- a/WebAPI/Controllers/CGGL/YF_PayMentBillController.cs
+++ b/WebAPI/Controllers/CGGL/YF_PayMentBillController.cs
@@ -372,6 +372,42 @@
objJsonResult.data = null;
return objJsonResult;
}
+ string HBillNo = "";
+ ds = oCN.RunProcReturn("select * from YF_PayMentBillMain where HInterID=" + HInterID, "YF_PayMentBillMain");
+ if (ds == null || ds.Tables[0].Rows.Count == 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "娌℃湁鏁版嵁锛屾棤娉曞垹闄わ紒";
+ objJsonResult.data = null;
+ return objJsonResult; ;
+ }
+ else
+ {
+ HBillNo = ds.Tables[0].Rows[0]["HBillNo"].ToString();
+ }
+
+ //鍒犻櫎鍓嶆帶鍒�=========================================
+ string sql1 = "exec h_p_YF_PayMentBill_BeforeDelCtrl " + HInterID + ",'" + HBillNo + "','" + user + "'";
+ ds = oCN.RunProcReturn(sql1, "h_p_YF_PayMentBill_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;
+ 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.ShowBill(long.Parse(HInterID), ref s) == false)
{
@@ -390,7 +426,7 @@
objJsonResult.data = 1;
return objJsonResult;
}
-
+ string sReturn = "";
oCN.BeginTran();
oCN.RunProc("delete from YF_PayMentBillMain where HInterID = " + HInterID);
@@ -398,6 +434,31 @@
oCN.Commit();
+ //鍒犻櫎鍚庢帶鍒�==================================================================================
+ string sql2 = "exec h_p_YF_PayMentBill_AfterDelCtrl " + HInterID + ",'" + HBillNo + "','" + user + "'";
+ ds = oCN.RunProcReturn(sql2, "h_p_YF_PayMentBill_AfterDelCtrl");
+ if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
+ {
+ sReturn = "鍒犻櫎鍚庡垽鏂け璐ワ紝璇蜂笌缃戠粶绠$悊浜哄憳鑱旂郴";
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍒犻櫎澶辫触!鍘熷洜:" + sReturn;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
+ {
+ sReturn = ds.Tables[0].Rows[0]["HRemark"].ToString();
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍒犻櫎澶辫触!鍘熷洜:" + sReturn;
+ objJsonResult.data = null;
+ oCN.RollBack();
+ return objJsonResult;
+ }
+ //==============================================================================================
+
objJsonResult.code = "1";
objJsonResult.count = 1;
objJsonResult.Message = "Sucess锛�";
--
Gitblit v1.9.1