From c3ad7025d45c0cd270396e83e6ba0e200d64c575 Mon Sep 17 00:00:00 2001
From: ch <37327@LLOOCCY>
Date: 星期日, 31 七月 2022 14:59:32 +0800
Subject: [PATCH] 修改了 生产任务单维护根据单据号倒序排列 以及流转卡 已经有下游进出站单后,不允许删除
---
WebAPI/Controllers/CJGL/Sc_ProcessExchangeBillController.cs | 25 +++++++++++++++++++++++--
1 files changed, 23 insertions(+), 2 deletions(-)
diff --git a/WebAPI/Controllers/CJGL/Sc_ProcessExchangeBillController.cs b/WebAPI/Controllers/CJGL/Sc_ProcessExchangeBillController.cs
index c8f77a8..4e378da 100644
--- a/WebAPI/Controllers/CJGL/Sc_ProcessExchangeBillController.cs
+++ b/WebAPI/Controllers/CJGL/Sc_ProcessExchangeBillController.cs
@@ -34,6 +34,7 @@
string msg2 = sArray[0].ToString();
string msg3 = sArray[1].ToString();
string msg4 = sArray[2].ToString();
+ string msg5 = sArray[3].ToString();
string UserName = "";
ListModels oListModels = new ListModels();
@@ -93,7 +94,7 @@
//淇濆瓨
//淇濆瓨瀹屾瘯鍚庡鐞�
bool bResult;
- if (oBill.omodel.HInterID == 0)
+ if (msg5 == "xz")
{
// bResult = oBill.AddBill(ref DBUtility.ClsPub.sExeReturnInfo);
bResult = oBill.AddBill(ref DBUtility.ClsPub.sExeReturnInfo);
@@ -528,7 +529,7 @@
/// <returns></returns>
[Route("Sc_ProcessExchangeBill/DeltetProcessExchangeBillByID")]
[HttpGet]
- public object DeltetProcessExchangeBillByID(string HInterID, string user)
+ public object DeltetProcessExchangeBillByID(string HInterID,int HPRDORGID, string user)
{
//缂栬緫鏉冮檺
if (!DBUtility.ClsPub.Security_Log("Sc_ProcessExchangeBill_Drop", 1, false, user))
@@ -551,7 +552,27 @@
objJsonResult.data = null;
return objJsonResult;
}
+
+
+ //鍒犻櫎鍓嶅垽鏂叧鑱旀暟閲�
+ SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ DataSet ds;
+ ds = oCn.RunProcReturn("select ct from ( " +
+ " select 1 ct from Sc_StationInBillMain Where HProcExchInterID=" + lngBillKey + " " +
+ " union all " +
+ " select 1 from Sc_StationOutBillMain Where HProcExchInterID=" + lngBillKey + " ) as a ", "Sc_ProcExchReportSub");
+ if (ds.Tables[0].Rows.Count != 0)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "娴佽浆鍗″凡缁忔湁涓嬫父杩涘嚭绔欏崟鍚庯紝涓嶅厑璁稿垹闄わ紒";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+
+
DAL.ClsSc_ProcessExchangeBill oBill = new DAL.ClsSc_ProcessExchangeBill();
+ DBUtility.ClsPub.HOrgID = HPRDORGID;
if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo))
{
if (oBill.omodel.HBillStatus > 1)
--
Gitblit v1.9.1