From 32ad85a377b00bc54ad7f15a45d7631d3e2b10d5 Mon Sep 17 00:00:00 2001
From: wjc <1243177876@qq.com>
Date: 星期一, 13 六月 2022 17:41:12 +0800
Subject: [PATCH] 2022年06月13日17:39:46

---
 HDL_ON/DAL/Server/HttpServerRequest.cs |   25 ++++++++++++++++++++++++-
 1 files changed, 24 insertions(+), 1 deletions(-)

diff --git a/HDL_ON/DAL/Server/HttpServerRequest.cs b/HDL_ON/DAL/Server/HttpServerRequest.cs
index 4741b1c..0e0a902 100644
--- a/HDL_ON/DAL/Server/HttpServerRequest.cs
+++ b/HDL_ON/DAL/Server/HttpServerRequest.cs
@@ -45,13 +45,17 @@
         /// <param name="deviceId">璁惧ID</param>
         /// <param name="deviceKey">鍔熻兘鏌ヨ绫诲瀷锛歱m25</param>
         /// <returns></returns>
-        public ResponsePackNew GetSensorHistory(string qType, string deviceId, string deviceKey)
+        public ResponsePackNew GetSensorHistory(string qType, string deviceId, string deviceKey,string time = "")
         {
             Dictionary<string, object> d = new Dictionary<string, object>();
             d.Add("type", qType);
             d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
             d.Add("deviceId", deviceId);
             d.Add("key", deviceKey);
+            if(time!= "")
+            {
+                d.Add("time", time);
+            }
 
             var requestJson = HttpUtil.GetSignRequestJson(d);
             return HttpUtil.RequestHttpsPost(NewAPI.Api_Post_EnvironmentalSensorHistoricalData, requestJson);
@@ -2617,6 +2621,25 @@
             var pack = HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_FL_Check, requestJson);
             return pack;
         }
+        /// <summary>
+        /// 鑾峰彇闂ㄥ彛鏈哄緲寰婃姤璀︽暟鎹�
+        /// </summary>
+        /// <param name="deviceId"></param>
+        /// <returns></returns>
+        public ResponsePackNew GetAlarmRecords(string deviceId, int pageSize, int pageNo, string alarmType = "PROWLER_ALARM")
+        {
+            Dictionary<string, object> d = new Dictionary<string, object>();
+            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
+            d.Add("deviceId", deviceId);
+            d.Add("alarmType", alarmType);
+            d.Add("pageSize", pageSize);
+            d.Add("pageNo", pageNo);
+            var requestJson = HttpUtil.GetSignRequestJson(d);
+            var pack = HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_ALARM_RECORDS, requestJson);
+            return pack;
+
+        }
+
         #endregion
 
         #region 鈻� 闂ㄩ攣鐩稿叧____________________________

--
Gitblit v1.8.0