From cd70a2a8a2bdebf51259d8f39ed110a34b9be9e5 Mon Sep 17 00:00:00 2001 From: wxr <464027401@qq.com> Date: 星期二, 11 四月 2023 14:50:21 +0800 Subject: [PATCH] 修改启动屏幕 --- HDL_ON/Common/ApiUtlis.cs | 78 +++++++++++++++++++++++++++++++++++++-- 1 files changed, 74 insertions(+), 4 deletions(-) diff --git a/HDL_ON/Common/ApiUtlis.cs b/HDL_ON/Common/ApiUtlis.cs index 1e28e4d..9661856 100644 --- a/HDL_ON/Common/ApiUtlis.cs +++ b/HDL_ON/Common/ApiUtlis.cs @@ -140,6 +140,7 @@ // return; //} + //return; try { @@ -236,7 +237,6 @@ - //===================璇诲彇鍙瀵硅鏁版嵁========================== //鍒ゆ柇鏄惁鏈夊彲瑙嗗璁叉暟鎹紝鏈夊垯鏄剧ず鍙瀵硅icon //var flVideoInfo = HttpRequest.CheckFlVideo(); @@ -282,6 +282,7 @@ } } + //======================鑾峰彇Sip璐﹀彿骞朵笖鍒濆鍖朣DK鍙瀵硅璁惧鍒楄〃==================== //濡傛灉妫�娴嬬嚎绋嬫病鍚姩锛屾墠缁х画涓嬮潰鎿嶄綔 鍥犱负App鏈夊彲鑳藉垰鍚姩椹笂鏀跺埌鎺ㄩ�佷簡锛岀劧鍚庢墠鎵ц鍒拌繖閲� if (HDLLinphone.Current.CheckIncomingCallThreadIsNull()) @@ -297,6 +298,7 @@ } else if (isInterphoneType_FREEVIEW) { + //HDLLinphone鍙瀵硅,鑾峰彇Sip璐﹀彿骞跺垵濮嬪寲SDK HDLCallVideoInfo callVideoInfo = new HDLCallVideoInfo(); callVideoInfo.HomeId = DB_ResidenceData.Instance.CurrentRegion.id; @@ -310,6 +312,8 @@ HDLLinphone.Current.LogoutAllAccount(); } } + + //======================鐧诲綍鍏ㄨ閫�==================== if (isInterphoneType_FREEVIEW) @@ -345,12 +349,78 @@ complateDevice = true; MainPage.Log($"============璁惧============瀹屾垚" + FunctionList.List.Functions.Count); } + + +#if DEBUG + DB_ResidenceData.Instance.HomeGateway.isSupportGroupControl = true; +#endif + if (DB_ResidenceData.Instance.HomeGateway.isSupportGroupControl) + { + var pack = Ins.HttpRequest.GetGroupControlList(); + if (pack != null) + { + if (pack.Code == StateCode.SUCCESS) + { + try + { + var groupControlList = JsonConvert.DeserializeObject<List<GroupControl>>(pack.Data.ToString()); + var readSidList = new List<string>(); + foreach(var temp in groupControlList) + { + FunctionList.List.groupControls.Clear(); + readSidList.Add(temp.userDeviceGroupControlId); + if (readSidList.Count >= 20) + { + var data = Ins.httpRequest.GetGroupControInfo(readSidList); + if(data != null) + { + if(data.Code == StateCode.SUCCESS) + { + var groupControlInfoList = JsonConvert.DeserializeObject<List<GroupControl>>(data.Data.ToString()); + FunctionList.List.groupControls.AddRange(groupControlInfoList); + } + else + { + IMessageCommon.Current.ShowErrorInfoAlter(pack.Code); + } + } + readSidList.Clear(); + } + } + if (readSidList.Count > 0) + { + var data = Ins.httpRequest.GetGroupControInfo(readSidList); + if (data != null) + { + if (data.Code == StateCode.SUCCESS) + { + var groupControlInfoList = JsonConvert.DeserializeObject<List<GroupControl>>(data.Data.ToString()); + FunctionList.List.groupControls.AddRange(groupControlInfoList); + } + else + { + IMessageCommon.Current.ShowErrorInfoAlter(pack.Code); + } + } + readSidList.Clear(); + } + } + catch (Exception ex) + { + MainPage.Log($"璇诲彇缁勬帶鍒楄〃澶辫触:{ex.Message}"); + } + } + else + { + IMessageCommon.Current.ShowErrorInfoAlter(pack.Code); + } + } + } + + //}) //{ IsBackground = true }.Start(); - ////===================鍦烘櫙========================== - //new System.Threading.Thread(() => - //{ try { complateScene = false; -- Gitblit v1.8.0