From dbfebaff9e8f5b10f8037c87971fb9d3edf025d3 Mon Sep 17 00:00:00 2001
From: zrg <z18737863051@163.com>
Date: 星期三, 02 四月 2025 17:27:29 +0800
Subject: [PATCH] 工程项目 增加 部门 字段, 工程项目 (任务类)任务大类和任务项目分类和日期, 任何一项 变化时,都要 刷新下 项目代码;通过存储过程 来 获取 项目代码
---
WebAPI/DbUntil/DataFormatUntil.cs | 24 ++++++++++++++++++++++++
1 files changed, 24 insertions(+), 0 deletions(-)
diff --git a/WebAPI/DbUntil/DataFormatUntil.cs b/WebAPI/DbUntil/DataFormatUntil.cs
index 5779273..381cd8d 100644
--- a/WebAPI/DbUntil/DataFormatUntil.cs
+++ b/WebAPI/DbUntil/DataFormatUntil.cs
@@ -4,6 +4,7 @@
using System.Linq;
using System.Reflection;
using System.Web;
+using Newtonsoft.Json;
namespace WebAPI.DbUntil
{
@@ -64,5 +65,28 @@
}
return entity;
}
+
+ #region 杩斿洖sql褰卞搷琛屾暟
+ public static int BackRowCount(string sql,string tableName)
+ {
+ return new SQLHelper.ClsCN().RunProcReturn(sql, tableName).Tables[0].Rows.Count;
+ }
+ #endregion
+
+ #region 杩斿洖sql杩斿洖鐨勬暟鎹爣棰�
+ public static List<object> BackColTitle(DataSet ds)
+ {
+ List<object> columnNameList = new List<object>();
+ foreach (DataColumn col in ds.Tables[0].Columns)
+ {
+
+ Type dataType = col.DataType;
+ string ColmString = "{\"ColmName\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
+ columnNameList.Add(JsonConvert.DeserializeObject(ColmString));
+ }
+ return columnNameList;
+ }
+ #endregion
+
}
}
\ No newline at end of file
--
Gitblit v1.9.1