From 067596ed46c962ce38d90a3ed33e9c55f184225c Mon Sep 17 00:00:00 2001
From: duhe <226547893@qq.com>
Date: 星期二, 03 六月 2025 11:16:30 +0800
Subject: [PATCH] 器具主档:删除时判断是否已经审核,若已经审核则删除失败

---
 WebAPI/Controllers/BaseSet/Gy_MaterialController.cs |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)

diff --git a/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs b/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
index caeec5c..a7fd6f6 100644
--- a/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
+++ b/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
@@ -2637,6 +2637,17 @@
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
+
+                ds = oCN.RunProcReturn("select * from Gy_MouldFileMain where HInterID = " + hmainid + " and ISNULL(HChecker,'') <> ''", "Gy_MouldFileMain");
+                if (ds.Tables[0].Rows.Count > 0)
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鍒犻櫎澶辫触锛佸崟鎹凡瀹℃牳锛�";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+
                 if (oBill.DeleteBill(hmainid, ref DBUtility.ClsPub.sExeReturnInfo))
                 {
                     oCN.BeginTran();

--
Gitblit v1.9.1