From 2e2f1f542db7d709813efd6dcce14e3bc076bfa0 Mon Sep 17 00:00:00 2001
From: 13693261870 <252740454@qq.com>
Date: 星期四, 03 八月 2023 11:45:31 +0800
Subject: [PATCH] 1

---
 ExportMap/db/TaskDBHelper.cs |   15 ++++++++++++++-
 1 files changed, 14 insertions(+), 1 deletions(-)

diff --git a/ExportMap/db/TaskDBHelper.cs b/ExportMap/db/TaskDBHelper.cs
index 4acb91e..85d97b5 100644
--- a/ExportMap/db/TaskDBHelper.cs
+++ b/ExportMap/db/TaskDBHelper.cs
@@ -12,13 +12,26 @@
     public class TaskDBHelper
     {
         /// <summary>
+        /// 鏍规嵁ID鏌ヨ
+        /// </summary>
+        public static SysTask SelectById(int id)
+        {
+            string sql = string.Format("select * from lf.sys_task where id = {0} order by id desc", id);
+
+            DataTable dt = Tools.DBHelper.GetDataTable(sql);
+            List<SysTask> list = ModelHandler.FillModel<SysTask>(dt);
+
+            return null == list || list.Count == 0 ? null : list[0];
+        }
+
+        /// <summary>
         /// 鏍规嵁ID闆嗗悎鏌ヨ
         /// </summary>
         public static List<SysTask> SelectByIds(List<int> ids)
         {
             string sql = string.Format("select * from lf.sys_task where id in ({0}) order by id desc", string.Join(",", ids.ToArray()));
 
-            DataTable dt = SQLiteHelper.GetDataTable(sql);
+            DataTable dt = Tools.DBHelper.GetDataTable(sql);
             List<SysTask> list = ModelHandler.FillModel<SysTask>(dt);
 
             return list;

--
Gitblit v1.9.3