From ddbdac2e9cd8258508fb96ca0eb58a9e222b8631 Mon Sep 17 00:00:00 2001 From: cnf <3200815559@qq.com> Date: 星期一, 24 三月 2025 14:51:04 +0800 Subject: [PATCH] 生产制造单修改 --- MES.Service/service/SentLaboratory/SaveLaboratoryManager.cs | 26 ++++++++++++++++++++++++++ 1 files changed, 26 insertions(+), 0 deletions(-) diff --git a/MES.Service/service/SentLaboratory/SaveLaboratoryManager.cs b/MES.Service/service/SentLaboratory/SaveLaboratoryManager.cs index dbfa7b9..5eff960 100644 --- a/MES.Service/service/SentLaboratory/SaveLaboratoryManager.cs +++ b/MES.Service/service/SentLaboratory/SaveLaboratoryManager.cs @@ -154,4 +154,30 @@ //} } + + public string DeleteLaboratory(string JYDH) + { + try + { + var db = SqlSugarHelper.GetInstance(); + // 鍋囪 db 鏄� SQLSugar 鐨� SqlSugarClient 瀹炰緥 + var result = db.Deleteable<UpdateMesQmsSample>() + .Where(t => t.JYDH == JYDH) // 鏍规嵁 JYDH 鍒犻櫎 + .ExecuteCommand(); + + if (result > 0) + { + return "鍒犻櫎鎴愬姛锛�"; + } + else + { + return "鏈壘鍒板尮閰嶇殑璁板綍锛屽垹闄ゅけ璐ャ��"; + } + } + catch (Exception ex) + { + return "鍒犻櫎澶辫触锛岄敊璇俊鎭細" + ex.Message; + } + } + } -- Gitblit v1.9.3