From 0605260d8529635c9dbef283bb5f6b85300a3503 Mon Sep 17 00:00:00 2001
From: llj <132905093+newwwwwwtree@users.noreply.github.com>
Date: 星期三, 14 一月 2026 10:24:10 +0800
Subject: [PATCH] 1
---
WebAPI/Controllers/MJGL/Sc_MouldReportController.cs | 110 ++++++++++++++++++++++++++++++++++++++++++++++++++++--
1 files changed, 105 insertions(+), 5 deletions(-)
diff --git a/WebAPI/Controllers/MJGL/Sc_MouldReportController.cs b/WebAPI/Controllers/MJGL/Sc_MouldReportController.cs
index c83b66b..2834c61 100644
--- a/WebAPI/Controllers/MJGL/Sc_MouldReportController.cs
+++ b/WebAPI/Controllers/MJGL/Sc_MouldReportController.cs
@@ -72,11 +72,7 @@
#endregion
#region 鍣ㄥ叿淇濆吇浠诲姟锛堜粖鏃ュ緟淇濆吇銆佷粖鏃ュ凡淇濆吇銆佷粖澶╁叏閮ㄤ换鍔★級
- /// <summary>
- /// 杩斿洖鍣ㄥ叿淇濆吇浠诲姟
- ///鍙傛暟锛歴tring sql銆�
- ///杩斿洖鍊硷細object銆�
- /// </summary>
+
[Route("Sc_MouldMaintainTaskReport/MaintainList")]
[HttpGet]
public object MaintainList(string user)
@@ -86,6 +82,61 @@
List<object> columnNameList = new List<object>();
ds = oCN.RunProcReturn("exec h_p_Sc_MouldMaintainTaskReport " + user, "h_p_Sc_MouldMaintainTaskReport");
+
+ if (ds.Tables[0].Rows.Count != 0 || ds != null)
+ {
+ //娣诲姞鍒楀悕
+ foreach (DataColumn col in ds.Tables[0].Columns)
+ {
+ Type dataType = col.DataType;
+ string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
+ columnNameList.Add(JsonConvert.DeserializeObject(ColmString));//鑾峰彇鍒癉ataColumn鍒楀璞$殑鍒楀悕
+ }
+
+ objJsonResult.code = "1";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "Sucess锛�";
+ objJsonResult.data = ds;
+ objJsonResult.list = columnNameList;
+ return objJsonResult;
+ }
+ else
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "鏃犳暟鎹�";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+
+ }
+ catch (Exception e)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "Exception锛�" + e.ToString();
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
+
+ [Route("Sc_MouldMaintainTaskReport/MaintainList_APP")]
+ [HttpGet]
+ public object MaintainList_APP(string sWhere, string user)
+ {
+ try
+ {
+ List<object> columnNameList = new List<object>();
+
+ Dictionary<object, object> dic = Newtonsoft.Json.JsonConvert.DeserializeObject<Dictionary<object, object>>(sWhere);
+
+ string HBeginDate = dic["HBeginDate"].ToString();//寮�濮嬫棩鏈�
+ string HEndDate = dic["HEndDate"].ToString();//缁撴潫鏃ユ湡
+
+
+ ds = oCN.RunProcReturn("exec h_p_Sc_MouldMaintainTaskReport_APP '" + HBeginDate + "','" + HEndDate + "','" + user + "'", "h_p_Sc_MouldMaintainTaskReport_APP");
+
+
if (ds.Tables[0].Rows.Count != 0 || ds != null)
{
@@ -233,5 +284,54 @@
}
#endregion
+ #region 妯″叿淇濆吇閫炬湡棰勮鎶ヨ〃
+ [Route("Sc_MouldRepairCheckTaskReport/Sc_MoldMainoverdueWarnReport")]
+ [HttpGet]
+ public object Sc_MoldMainoverdueWarnReport(string HMouldTypeID, string user)
+ {
+ try
+ {
+ List<object> columnNameList = new List<object>();
+
+ ds = oCN.RunProcReturn("exec h_p_Sc_MoldMainoverdueWarnReport " + HMouldTypeID, "h_p_Sc_MoldMainoverdueWarnReport");
+
+ if (ds.Tables[0].Rows.Count != 0 || ds != null)
+ {
+ //娣诲姞鍒楀悕
+ foreach (DataColumn col in ds.Tables[0].Columns)
+ {
+ Type dataType = col.DataType;
+ string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
+ columnNameList.Add(JsonConvert.DeserializeObject(ColmString));//鑾峰彇鍒癉ataColumn鍒楀璞$殑鍒楀悕
+ }
+
+ objJsonResult.code = "1";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "Sucess锛�";
+ objJsonResult.data = ds.Tables[0];
+ objJsonResult.list = columnNameList;
+ return objJsonResult;
+ }
+ else
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "鏃犳暟鎹�";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+
+ }
+ catch (Exception e)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "Exception锛�" + e.ToString();
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
+ #endregion
+
}
}
--
Gitblit v1.9.1