From 97eb1934697f8bd6d16ba1f5547752ab65330836 Mon Sep 17 00:00:00 2001
From: yusijie <ysj@hz-kingdee.com>
Date: 星期五, 05 五月 2023 10:57:30 +0800
Subject: [PATCH] 条码删除权限,工艺路线
---
WebAPI/Controllers/BaseSet/Gy_MaterialController.cs | 48 +++++++++++++++++++++++++-----------------------
1 files changed, 25 insertions(+), 23 deletions(-)
diff --git a/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs b/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
index 3def53a..2a61065 100644
--- a/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
+++ b/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
@@ -608,17 +608,7 @@
string HInterID = HInter.Replace("\"", "");
string user = sArray[1].ToString();
string HBarCode = sArray[2].ToString().Replace("\"","");
- string HComputerName = SystemInformation.ComputerName; //璁惧鍚嶇О
-
- //缂栬緫鏉冮檺
- if (!DBUtility.ClsPub.Security_Log("Gy_BarCodeBillList_Edit", 1, false, user))
- {
- objJsonResult.code = "0";
- objJsonResult.count = 0;
- objJsonResult.Message = "鏃犲垹闄ゆ潈闄愶紒";
- objJsonResult.data = null;
- return objJsonResult;
- }
+ string HComputerName = SystemInformation.ComputerName; //璁惧鍚嶇О
try
{
@@ -626,6 +616,16 @@
string[] NewBarCode;
NewBarCode = HBarCode.Split(Convert.ToChar(","));
+
+ //缂栬緫鏉冮檺
+ if (!DBUtility.ClsPub.Security_Log("Gy_BarCodeBill_Del", 1, false, user))
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "鏃犲垹闄ゆ潈闄愶紒";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
//鍒犻櫎鏉$爜鍓嶈繘琛屽垽鏂�
Ds = oCN.RunProcReturn("exec h_p_Gy_BarCodeBill_MulDelete_Before '" + HInterID + "','" + HBarCode + "'", "h_p_Gy_BarCodeBill_MulDelete_Before", ref DBUtility.ClsPub.sExeReturnInfo);
@@ -664,18 +664,20 @@
{
oCN.BeginTran();
- ////鑾峰彇绯荤粺鍙傛暟
- //string Ret = "";
- //if (oSystemParameter.ShowBill(ref Ret))
- //{
- // //鍒ゆ柇鏄惁鍙兘鍒犻櫎鑷繁鐢熸垚鐨勬潯鐮�
- // if (oSystemParameter.omodel.BarCode_DeleterAndMakerllustSame != "榫欏北姹介厤") //绯荤粺鍙傛暟
- // {
-
- // }
- //}
-
- oCN.RunProc("Delete from Gy_BarCodeBill Where HItemID in (" + HInterID + ")");
+ //鑾峰彇绯荤粺鍙傛暟
+ string Ret = "";
+ if (oSystemParameter.ShowBill(ref Ret))
+ {
+ //鍒ゆ柇鏄惁鍙兘鍒犻櫎鑷繁鐢熸垚鐨勬潯鐮�
+ if (oSystemParameter.omodel.BarCode_DeleterAndMakerMustSame == "Y") //绯荤粺鍙傛暟
+ {
+ oCN.RunProc("Delete from Gy_BarCodeBill Where HItemID in (" + HInterID + ")" + " and HMaker = '" + user + "'");
+ }
+ else
+ {
+ oCN.RunProc("Delete from Gy_BarCodeBill Where HItemID in (" + HInterID + ")");
+ }
+ }
//鍐欏叆绯荤粺鏃ュ織
for (int i = 0; i <= NewBarCode.Length - 1; i++)
--
Gitblit v1.9.1