xm
2021-12-01 6d73bf6e816570291865674bef8bce8972e4de3f
HDL_ON/UI/UI1-Login/LoginPageBLL.cs
@@ -174,7 +174,7 @@
        /// <param name="type">是否选择手机登录</param>
        void LoginTypeChange(bool isPhone)
        {
            if(isPhone)
            if (isPhone)
            {
                if (loginType == 0)
                    return;
@@ -598,7 +598,7 @@
                            if (verAccount == etPassword.Text.Trim())
                            {
                                //跳转页面----
                                MainPage.GoUserPage();
                                MainPage.GoUserPage(true);
                                return;
                            }
                        });
@@ -629,15 +629,20 @@
                            //}
                            Application.RunOnMainThread(() =>
                            {
                                //20201223-登录成功之后,将下载数据完成标记标记为false,防止主页提前加载
                                Common.ApiUtlis.Ins.DownloadDataComplete = false;
                                //跳转页面----
                                MainPage.GoUserPage();
                                MainPage.GoUserPage(true);
                            });
                        }
                        else
                        {
                            BindingResidencePage page = new BindingResidencePage();
                            MainPage.BaseView.AddChidren(page);
                            page.LoadView();
                            //Application.RunOnMainThread(() =>
                            //{
                            //    BindingResidencePage page = new BindingResidencePage();
                            //    MainPage.BaseView.AddChidren(page);
                            //    page.LoadView();
                            //});
@@ -646,7 +651,7 @@
                            UserInfo.Current.LastTime = DateTime.MinValue;
                            UserInfo.Current.SaveUserInfo();
                            //登录失败,请先添加住宅!
                            Utlis.ShowAlertOnMainThread(Language.StringByID(StringId.FailedGetHomeList));
                            //Utlis.ShowAlertOnMainThread(Language.StringByID(StringId.FailedGetHomeList));
                        }
                    }
                }
@@ -764,7 +769,7 @@
                    IMessageCommon.Current.ShowErrorInfoAlter(loginResult.Code);
                });
            }
            return result;
        }
@@ -790,7 +795,7 @@
                    var unlockDatetime = Utlis.UnixToDateTimeMS(revertData.unlockTime);
                    var unlockTimeInt = unlockDatetime.Minute - DateTime.Now.Minute;
                    if(unlockTimeInt <= 0)
                    if (unlockTimeInt <= 0)
                    {
                        unlockTimeInt = 1;
                    }
@@ -809,8 +814,8 @@
        bool LoadMethod_GetResidences()
        {
            var result = false;
            var responsePack = pm.GetHomePager();
            if (responsePack == StateCode.SUCCESS)
            var code = pm.GetHomePager();
            if (code == StateCode.SUCCESS)
            {
                ////2020-11-13 待确认,没有住宅,不算登录成功
                //if (UserInfo.Current.regionList != null && UserInfo.Current.regionList.Count > 0)
@@ -820,10 +825,17 @@
                //2020-12-10 没有住宅登录成功,但是不能进入主界面
                result = true;
            }
            else if( code == "null")
            {
                Application.RunOnMainThread(() =>
                {
                    MainPage.GoUserPage(false);
                });
            }
            else
            {
                // 提示错误
                IMessageCommon.Current.ShowErrorInfoAlter(responsePack);
                IMessageCommon.Current.ShowErrorInfoAlter(code);
            }
            return result;
        }
@@ -852,7 +864,7 @@
                        MainPage.Log($"login callBackAction : {ex.Message}");
                    }
                };
                var registerPage = new RegisterPage(autoLoginAction);
                registerPage.Show();