From 25429f085093d89d543a0b90e30d0d62d1b7dac9 Mon Sep 17 00:00:00 2001 From: hxb <hxb@hdlchina.com.cn> Date: 星期二, 30 八月 2022 09:37:38 +0800 Subject: [PATCH] 合并了IOS的代码 --- ZigbeeApp/Shared/Phone/UserView/HomePage.cs | 38 +++++++++++++++++++------------------- 1 files changed, 19 insertions(+), 19 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/UserView/HomePage.cs b/ZigbeeApp/Shared/Phone/UserView/HomePage.cs old mode 100755 new mode 100644 index 8503e8e..be0d61a --- a/ZigbeeApp/Shared/Phone/UserView/HomePage.cs +++ b/ZigbeeApp/Shared/Phone/UserView/HomePage.cs @@ -53,28 +53,30 @@ if (Config.Instance.IsLogin) { //鏄剧ず鍚姩椤� - this.ShowLoginLoadView(); CommonPage.Loading.Start(); UserCenter.HdlThreadLogic.Current.RunThread(() => { //鐧诲綍 var loginSuccess = LoginByPWDAsync(Config.Instance.Account, Config.Instance.Password); - //鐧诲綍鎴愬姛,鎴栬�呮病鏈夌綉缁滈兘鍙互鐧诲綍 if (loginSuccess == 1 || loginSuccess == 2) { - var homes = UserCenter.HdlResidenceLogic.Current.GetHomeListsFromDb(); + var homes = UserCenter.HdlResidenceLogic.Current.GetHomeListsFromDb(true); //鍒锋柊涓汉涓績鐨勫唴瀛樺強绾跨▼ - UserCenter.UserCenterLogic.InitUserCenterMenmoryAndThread(); + bool result = UserCenter.UserCenterLogic.InitUserCenterMenmoryAndThread(); //鍚姩ZigBee ZigBee.Common.Application.Init(); UserCenter.HdlThreadLogic.Current.RunMain(() => { CommonPage.Instance.RemoveViewByTag("Login"); - UserPage.Instance.ReFreshControl(); CommonPage.Loading.Hide(); + if (result == true) + { + //false:寮�鍚簡璋冭瘯鍔熻兘 + UserPage.Instance.ReFreshControl(); + } }); } else @@ -104,16 +106,6 @@ } } - /// <summary> - /// 鏄剧ず鍚姩椤� - /// </summary> - public void ShowLoginLoadView() - { - var loginLoad = new LoginLoading { }; - CommonPage.Instance.AddChidren(loginLoad); - loginLoad.Show(); - } - /// <summary> /// 1:鐧诲綍鎴愬姛 0:瀵嗙爜閿欒 -1:鍏朵粬寮傚父 2:鏃犳硶鑱旂綉 /// </summary> @@ -128,9 +120,7 @@ var requestObj = new SendDataToServer.LoginObj { Account = account, - Password = password, - Source = source, - Company = company + Password = password }; var requestJson = Newtonsoft.Json.JsonConvert.SerializeObject(requestObj); //鐧婚檰鎺ュ彛鐗规畩,闇�瑕佸揩涓�鐐硅闂�,璁剧疆3绉掕秴鏃� @@ -155,7 +145,12 @@ Config.Instance.LoginToken = revertData.Token; //涓婃姤璁惧ID CommonPage.Instance.PushRegID(); - isLoginSuccess = 1; + isLoginSuccess = 1; + +//#if iOS +// //鍒濆鍖栧叏瑙嗛�� +// Shared.IOS.HDLFVSDK.Video.Init("",revertData.UserID.ToString()); +//#endif } else if (stateCodeStr == "YOUDATANOISLOCALREGION") { @@ -187,6 +182,11 @@ //璐﹀彿涓嶅瓨鍦� isLoginSuccess = 0; } + else if (stateCodeStr == "BERESTRICT") + { + //姝よ处鍙锋棤鏉冪櫥褰� + isLoginSuccess = 0; + } return isLoginSuccess; } } -- Gitblit v1.8.0