From d72ca686a3e262693f8a6e45e747e8e8da43335b Mon Sep 17 00:00:00 2001
From: JLChen <551775569@qq.com>
Date: 星期二, 06 七月 2021 09:39:03 +0800
Subject: [PATCH] 2021-07-06 1.更新
---
HDL_ON/DAL/Server/HttpServerRequest.cs | 88 +++++++++++++++++++++++++++++++++++++++++++
1 files changed, 87 insertions(+), 1 deletions(-)
diff --git a/HDL_ON/DAL/Server/HttpServerRequest.cs b/HDL_ON/DAL/Server/HttpServerRequest.cs
index 63a7ec2..4658ffe 100644
--- a/HDL_ON/DAL/Server/HttpServerRequest.cs
+++ b/HDL_ON/DAL/Server/HttpServerRequest.cs
@@ -480,6 +480,7 @@
IsOthreShare = mHome.IsOtherShare,
accountType = mHome.accountType,
isRemoteControl = mHome.isRemoteControl,
+ isBindGateway = mHome.isBindGateway,
longitude = mHome.longitude,
latitude = mHome.latitude,
deliverstatus = mHome.deliverstatus,
@@ -491,7 +492,14 @@
Address = mHome.homeAddress,
isAllowCreateScene = mHome.isAllowCreateScene,
};
- UserInfo.Current.regionList.Add(home);
+ if (home.isBindGateway)
+ {
+ UserInfo.Current.regionList.Add(home);
+ }
+ }
+ if(UserInfo.Current.regionList.Count== 0)
+ {
+ return "null";
}
//-------濡傛灉璐﹀彿鏄娆$櫥褰�
if (DB_ResidenceData.Instance.CurrentRegion == null || string.IsNullOrEmpty(DB_ResidenceData.Instance.CurrentRegion.RegionID))
@@ -1781,6 +1789,56 @@
return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetDevcieList, requestJson);
}
/// <summary>
+ /// 鑾峰彇鎸囧畾绗笁鏂瑰搧鐗岀殑缁戝畾杩囩殑璁惧鍒楄〃
+ /// </summary>
+ /// <param name="productPlatform"></param>
+ /// <param name="productBrand"></param>
+ /// <returns></returns>
+ public ResponsePackNew Get3TyBrandBindDeviceList(string productPlatform, string productBrand)
+ {
+ Dictionary<string, object> d = new Dictionary<string, object>();
+ d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
+ d.Add("productPlatform", productPlatform);
+ d.Add("productBrand", productBrand);
+ d.Add("networkConfig", true);
+
+ var requestJson = HttpUtil.GetSignRequestJson(d);
+ return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetDevcieList, requestJson);
+ }
+ /// <summary>
+ /// 鑾峰彇鎸囧畾绗笁鏂瑰搧鐗岀殑璁惧鍒楄〃
+ /// </summary>
+ /// <param name="productPlatform"></param>
+ /// <param name="productBrand"></param>
+ /// <returns></returns>
+ public ResponsePackNew Get3TyBrandDeviceList(string productPlatform,string productBrand)
+ {
+ Dictionary<string, object> d = new Dictionary<string, object>();
+ d.Add("categoryType", 1);
+ d.Add("productPlatform", productPlatform);
+ d.Add("productBrand", productBrand);
+ d.Add("networkConfig", true);
+
+
+ var requestJson = HttpUtil.GetSignRequestJson(d);
+ return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_Get3tyBrandDevcieList, requestJson);
+ }
+
+ /// <summary>
+ /// 鑾峰彇璁惧璇︽儏
+ /// </summary>
+ /// <returns></returns>
+ public ResponsePackNew GetDeviceInfo(string functionId)
+ {
+ Dictionary<string, object> d = new Dictionary<string, object>();
+ d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
+ d.Add("deviceIds", new List<string>() { functionId });
+
+ var requestJson = HttpUtil.GetSignRequestJson(d);
+ return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetDevcieInfoList, requestJson);
+ }
+
+ /// <summary>
/// 鑾峰彇璁惧璇︽儏鍒楄〃
/// </summary>
/// <returns></returns>
@@ -1820,6 +1878,7 @@
d.Add("actions", actionObjs);
var requestJson = HttpUtil.GetSignRequestJson(d);
+ MainPage.Log($"{requestJson}");
return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_ControlDevice, requestJson);
}
/// <summary>
@@ -2160,5 +2219,32 @@
#endregion
+ #region 钀ょ煶浜慡DK鐩稿叧鎺ュ彛
+ /// <summary>
+ /// 娌充笢鑾峰彇钀ょ煶浜戝瓙璐﹀彿token鐨勬帴鍙�
+ /// </summary>
+ public ResponsePackNew EZGetChildToken()
+ {
+ Dictionary<string, object> d = new Dictionary<string, object>();
+ var requestJson = HttpUtil.GetSignRequestJson(d);
+ return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_EZ_GetChildToken, requestJson);
+ }
+ #endregion
+
+
+ #region 鍙瀵硅
+ /// <summary>
+ /// 妫�鏌ヤ綇瀹呮槸鍚︾粦瀹氫赴鏋�
+ /// </summary>
+ /// <returns></returns>
+ public ResponsePackNew CheckFlVideo()
+ {
+ Dictionary<string, object> d = new Dictionary<string, object>();
+ d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
+ var requestJson = HttpUtil.GetSignRequestJson(d);
+ var pack = HttpUtil.RequestHttpsPostFroHome( NewAPI.API_POST_FL_Check, requestJson);
+ return pack;
+ }
+ #endregion
}
}
\ No newline at end of file
--
Gitblit v1.8.0