From c0663fd653ae7aafad06d4f583f9a3b6faeb52d4 Mon Sep 17 00:00:00 2001
From: wtt <1985833171@qq.com>
Date: 星期五, 23 一月 2026 16:50:57 +0800
Subject: [PATCH] 1

---
 WebAPI/Controllers/BaseSet/Gy_MaterialController.cs |   16 +++++++++++++---
 1 files changed, 13 insertions(+), 3 deletions(-)

diff --git a/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs b/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
index 6a0abc9..37a42e5 100644
--- a/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
+++ b/WebAPI/Controllers/BaseSet/Gy_MaterialController.cs
@@ -3233,16 +3233,24 @@
                     return objJsonResult;
                 }
 
-                ds = oCN.RunProcReturn("select * from Gy_MouldFileMain where HInterID = " + hmainid + " and ISNULL(HChecker,'') <> '' and HPrintQty>0", "Gy_MouldFileMain");
+                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.Message = "鍒犻櫎澶辫触锛佸崟鎹凡瀹℃牳锛�";
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
-
+                ds = oCN.RunProcReturn("select * from Gy_MouldFileMain where HInterID = " + hmainid + "  and HPrintQty>0", "Gy_MouldFileMain");
+                if (ds.Tables[0].Rows.Count > 0)
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鍒犻櫎澶辫触锛佸崟鎹凡琚墦鍗帮紒";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
                 oCN.BeginTran();
                 //鍒犻櫎鍓嶆帶鍒�=========================================
                 ds = oCN.RunProcReturn("Exec h_p_Gy_MouldFile_BeforeDelCtrl " + hmainid + ",'" + User + "'", "h_p_Gy_MouldFile_BeforeDelCtrl");
@@ -4016,6 +4024,8 @@
                 DataSet ds = new DataSet();
                 ds = oCN.RunProcReturn("select * from Gy_MouldFileMain where HInterID=" + HInterID, "Gy_MouldFileMain");
                 DataRow dr = ds.Tables[0].Rows[0];
+                dr["HPrintQty"] = 0;
+
                 string Num = dr["HBarCode"].ToString();
                 string Num1 = Num.Substring(0, (Num.Length) - 5);
                 oCN.BeginTran();

--
Gitblit v1.9.1