From 8bae9699d6fa35e2ecc1b871e45b6d6d9cbe01f3 Mon Sep 17 00:00:00 2001 From: wtt <1985833171@qq.com> Date: 星期六, 05 十月 2024 13:46:49 +0800 Subject: [PATCH] 工艺路线多级审批反审核控制添加 --- WebAPI/Controllers/SCGL/Gy_SourceWorkStationSetController.cs | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 52 insertions(+), 0 deletions(-) diff --git a/WebAPI/Controllers/SCGL/Gy_SourceWorkStationSetController.cs b/WebAPI/Controllers/SCGL/Gy_SourceWorkStationSetController.cs index 3374d00..2c68baf 100644 --- a/WebAPI/Controllers/SCGL/Gy_SourceWorkStationSetController.cs +++ b/WebAPI/Controllers/SCGL/Gy_SourceWorkStationSetController.cs @@ -171,5 +171,57 @@ } #endregion + /// <summary> + /// 鐢熶骇宸ヤ綅鍒楄〃鍒犻櫎鍔熻兘 + /// </summary> + /// <returns></returns> + [Route("DeltetGy_SourceWorkStation")] + [HttpGet] + public object DeltetGy_SourceWorkStation(string HItemID, string user) + { + DataSet ds; + DataSet ds1; + try + { + + SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); + if (string.IsNullOrWhiteSpace(HItemID)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "HItemID涓虹┖锛�"; + objJsonResult.data = null; + return objJsonResult; + } + oCN.BeginTran();//寮�濮嬩簨鍔� + ds = oCN.RunProcReturn("select * from Gy_SourceWorkStationSet where HItemID=" + HItemID, "Gy_SourceWorkStationSet"); + if (ds == null || ds.Tables[0].Rows.Count == 0) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "娌℃湁鏁版嵁锛屾棤娉曞垹闄わ紒"; + objJsonResult.data = null; + return objJsonResult; ; + } + + oCN.RunProc("delete from Gy_SourceWorkStationSet where HItemID=" + HItemID); + oCN.Commit();//鎻愪氦浜嬪姟 + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "* 鏁版嵁鍒犻櫎鎴愬姛锛�"; + objJsonResult.data = null; + return objJsonResult; ; + + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍒犻櫎澶辫触锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + } } \ No newline at end of file -- Gitblit v1.9.1