From 330fb0fa0c0cc61b52857771f3875268c8b190c0 Mon Sep 17 00:00:00 2001
From: zzr99 <1940172413@qq.com>
Date: 星期三, 20 四月 2022 14:31:52 +0800
Subject: [PATCH] 数据导出

---
 WebAPI/Controllers/LMESController.cs |   57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++--
 1 files changed, 55 insertions(+), 2 deletions(-)

diff --git a/WebAPI/Controllers/LMESController.cs b/WebAPI/Controllers/LMESController.cs
index 16a2d83..3968123 100644
--- a/WebAPI/Controllers/LMESController.cs
+++ b/WebAPI/Controllers/LMESController.cs
@@ -1197,8 +1197,8 @@
                 {
                     objJsonResult.code = "1";
                     objJsonResult.count = 1;
-                    objJsonResult.Message = "Sucess";
-                    objJsonResult.data = null;
+                    objJsonResult.Message = "鑾峰彇淇℃伅鎴愬姛锛�";//杩斿洖鍓╀綑鏁伴噺
+                    objJsonResult.data = Pub_Class.ClsPub.isInt(ds.Tables[0].Rows[0]["HBackRemark"]);
                     return objJsonResult;
                 }
                 else
@@ -1220,6 +1220,59 @@
             }
         }
 
+        /// <summary>
+        /// 缂撳瓨琛ㄥ寘瑁呭崟璁板綍
+        ///鍙傛暟锛歴tring sql銆�
+        ///杩斿洖鍊硷細object銆�
+        /// </summary>
+        [Route("LEMS/PackUnionCacheList")]
+        [HttpGet]
+        public object PackUnionCacheList(string sWhere)
+        {
+            DataSet ds;
+            try
+            {
+                SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
+                if (sWhere == null || sWhere.Equals(""))
+                {
+                    ds = oCN.RunProcReturn("select top 5000 * from h_v_PackUnionBillCacheList order by 鎵爜鏃堕棿 desc", "h_v_PackUnionBillCacheList");
+                }
+                else
+                {
+                    string sql1 = "select * from h_v_PackUnionBillCacheList where 1 = 1 ";
+                    string sql = sql1 + sWhere;
+                    string sql2 = " order by 鎵爜鏃堕棿 desc";
+                    sql += sql2;
+                    ds = oCN.RunProcReturn(sql, "h_v_PackUnionBillCacheList");
+                }
+                if (ds == null || ds.Tables[0].Rows.Count == 0)
+                {
+                    objJsonResult.code = "0";
+                    objJsonResult.count = 0;
+                    objJsonResult.Message = "鏃犳暟鎹紒";
+                    objJsonResult.data = null;
+                    return objJsonResult;
+                }
+                else
+                {
+                    objJsonResult.code = "1";
+                    objJsonResult.count = 1;
+                    objJsonResult.Message = "Sucess锛�";
+                    objJsonResult.data = ds.Tables[0];
+                    return objJsonResult;
+                }
+
+            }
+            catch (Exception e)
+            {
+                objJsonResult.code = "0";
+                objJsonResult.count = 0;
+                objJsonResult.Message = "Exception锛�" + e.ToString();
+                objJsonResult.data = null;
+                return objJsonResult;
+            }
+        }
+
         //
     }
 }
\ No newline at end of file

--
Gitblit v1.9.1