From 877a3643ea89282775a2a5ca25a2d79fbdfad0b7 Mon Sep 17 00:00:00 2001
From: wtt <1985833171@qq.com>
Date: 星期四, 05 九月 2024 08:14:56 +0800
Subject: [PATCH] 1
---
WebAPI/Controllers/BaseSet/Gy_BarCodeBillController.cs | 90 +++++++++++++++++----------------------------
1 files changed, 34 insertions(+), 56 deletions(-)
diff --git a/WebAPI/Controllers/BaseSet/Gy_BarCodeBillController.cs b/WebAPI/Controllers/BaseSet/Gy_BarCodeBillController.cs
index c2d9913..7e406a4 100644
--- a/WebAPI/Controllers/BaseSet/Gy_BarCodeBillController.cs
+++ b/WebAPI/Controllers/BaseSet/Gy_BarCodeBillController.cs
@@ -27,73 +27,51 @@
/// <returns></returns>
[Route("Gy_BarCodeBillList/Sub_DeleteBill")]
[HttpGet]
- public object Sub_DeleteBill(long HInterID)
+ public object Sub_DeleteBill(long HInterID, string HBarCode)
{
- //缂栬緫鏉冮檺
- //if (!DBUtility.ClsPub.Security_Log("Sb_MouldRepairWorkBill_Delete", 1, true, DBUtility.ClsPub.CurUserName))
- //{
- // objJsonResult.code = "0";
- // objJsonResult.count = 0;
- // objJsonResult.Message = "鏃犲垹闄ゆ潈闄愶紒";
- // objJsonResult.data = null;
- // return objJsonResult;
- //}
-
-
- Int64 lngBillKey = 0;
- lngBillKey = DBUtility.ClsPub.isLong(HInterID);
- if (lngBillKey == 0)
+ DAL.ClsGy_BarCodeBill_Ctl oBill = new DAL.ClsGy_BarCodeBill_Ctl();
+ if (oBill.DeleteBill(HInterID, HBarCode, ref DBUtility.ClsPub.sExeReturnInfo))
{
objJsonResult.code = "0";
objJsonResult.count = 0;
- objJsonResult.Message = "鍗曟嵁ID涓虹┖锛�";
+ objJsonResult.Message = DBUtility.ClsPub.sExeReturnInfo;
objJsonResult.data = null;
return objJsonResult;
}
- DAL.ClsSb_MouldRepairWorkBill oBill = new DAL.ClsSb_MouldRepairWorkBill();
- if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo))
- {
- if (oBill.omodel.HBillStatus > 1)
- {
- objJsonResult.code = "0";
- objJsonResult.count = 0;
- objJsonResult.Message = "鍗曟嵁褰撳墠澶勪簬涓嶈兘鍒犻櫎鐘舵��,涓嶈兘鍒犻櫎锛�";
- objJsonResult.data = null;
- return objJsonResult;
- }
- if (oBill.omodel.HChecker != "")
- {
- objJsonResult.code = "0";
- objJsonResult.count = 0;
- objJsonResult.Message = "鍗曟嵁宸茬粡瀹℃牳,涓嶈兘鍒犻櫎锛�";
- objJsonResult.data = null;
- return objJsonResult;
- }
-
- bool IsDete = oBill.DeleteBill(oBill.omodel.HInterID, ref DBUtility.ClsPub.sExeReturnInfo);
- if (IsDete)
- {
- objJsonResult.code = "0";
- objJsonResult.count = 1;
- objJsonResult.Message = DBUtility.ClsPub.sExeReturnInfo;
- objJsonResult.data = null;
- return objJsonResult;
- }
- else
- {
-
- objJsonResult.code = "0";
- objJsonResult.count = 0;
- objJsonResult.Message = DBUtility.ClsPub.sExeReturnInfo;
- objJsonResult.data = null;
- return objJsonResult;
- }
- }
else
+ {
+ //鍒犻櫎鎴愬姛
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = DBUtility.ClsPub.sExeReturnInfo;
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
+
+ /// <summary>
+ /// 鏉$爜妗f鍒楄〃鎵归噺鍒犻櫎鍔熻兘
+ /// </summary>
+ /// <returns></returns>
+ [Route("Gy_BarCodeBillList/Sub_MulDeleteBill")]
+ [HttpGet]
+ public object Sub_MulDeleteBill(string sInterID, string sBarCode)
+ {
+ DAL.ClsGy_BarCodeBill_Ctl oBill = new DAL.ClsGy_BarCodeBill_Ctl();
+ if (oBill.MulDeleteBill(sInterID, sBarCode, ref DBUtility.ClsPub.sExeReturnInfo))
{
objJsonResult.code = "0";
objJsonResult.count = 0;
- objJsonResult.Message = "鍗曟嵁鏈壘鍒�";
+ objJsonResult.Message = DBUtility.ClsPub.sExeReturnInfo;
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ else
+ {
+ //鍒犻櫎鎴愬姛
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = DBUtility.ClsPub.sExeReturnInfo;
objJsonResult.data = null;
return objJsonResult;
}
--
Gitblit v1.9.1