From 18ca81b6dd7ad6cc89b07c8865be2b9b4a30e258 Mon Sep 17 00:00:00 2001
From: ch <37327@LLOOCCY>
Date: 星期一, 29 三月 2021 17:03:31 +0800
Subject: [PATCH] nothing
---
WebAPI/Controllers/WebAPIController.cs | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 58 insertions(+), 0 deletions(-)
diff --git a/WebAPI/Controllers/WebAPIController.cs b/WebAPI/Controllers/WebAPIController.cs
index a811605..8e6f6a2 100644
--- a/WebAPI/Controllers/WebAPIController.cs
+++ b/WebAPI/Controllers/WebAPIController.cs
@@ -329,6 +329,33 @@
}
+ //鍒犻櫎琛ㄨ褰�
+ [Route("Web/Delete_Table")]
+ [HttpGet]
+ public object Delete_Table(string sqlStr)
+ {
+ try
+ {
+ //SQLHelper oCn;
+ SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
+ oCN.RunProc(sqlStr);
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鍒犻櫎鎴愬姛锛�";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ catch (Exception)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "鍒犻櫎澶辫触锛佸紓甯�";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+
+ }
+
#region 鍩虹璧勬枡
/// <summary>
/// 鑾峰彇浠撳簱鍒楄〃
@@ -721,6 +748,37 @@
return objjson;
}
}
+
+ /// <summary>
+ /// 鑾峰彇褰撳墠鏁版嵁搴撳悕
+ /// </summary>
+ /// <returns></returns>
+ [Route("Web/GetDataBases")]
+ [HttpGet]
+ public object GetDataBases()
+ {
+ try
+ {
+ ClsCN oCn = new ClsCN();
+ DataSet oDs = new DataSet();
+ //==========
+ oDs = oCn.RunProcReturn("Select Name From Master..SysDataBases Where DbId=(Select Dbid From Master..SysProcesses Where Spid = @@spid)", "SysDataBases");
+ objjson.code = "1";
+ objjson.count = 1;
+ objjson.Message = "鑾峰彇鎴愬姛锛�";
+ objjson.data = oDs.Tables[0];
+ return objjson; ;
+ }
+ catch (Exception e)
+ {
+
+ objjson.code = "0";
+ objjson.count = 0;
+ objjson.Message = "鑾峰彇澶辫触锛佸紓甯�" + e.ToString();
+ objjson.data = null;
+ return objjson; ;
+ }
+ }
#endregion
}
--
Gitblit v1.9.1