xm
2020-07-21 9a4b76398009cf76c508d61f7e48fb6f5cb7ac2d
ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewEmailForm.cs
@@ -65,6 +65,8 @@
            btnLine.Y = txtValue.Bottom;
            btnLine.BackgroundColor = UserCenterColor.Current.ButtomLine;
            frame.AddChidren(btnLine);
            //联动线的状态
            txtValue.btnLine = btnLine;
            if (string.IsNullOrEmpty(UserCenterResourse.UserInfo.Email) == false)
            {
@@ -102,6 +104,7 @@
            btnErrorMsg.TextAlignment = TextAlignment.Center;
            btnErrorMsg.TextColor = 0xfff75858;
            btnErrorMsg.TextID = R.MyInternationalizationString.uVerificationCodeErrorInputAgain;
            btnErrorMsg.IsBold = true;
            bodyFrameLayout.AddChidren(btnErrorMsg);
            btnErrorMsg.Visible = false;
@@ -113,6 +116,9 @@
            btnOk.CanClick = false;
            btnOk.ButtonClickEvent += (sender, e) =>
            {
                //清空输入的值
                btnCodeControl.ClearInputValue();
                this.btnErrorMsg.Visible = false;
                //检测邮箱的地址
                if (this.CheckEmail(txtValue.Text.Trim()) == false)
@@ -145,12 +151,12 @@
        /// <summary>
        /// 发送验证码到邮箱
        /// </summary>
        private async void SendCodeToEmail(BottomClickButton btnNext, string Email)
        private void SendCodeToEmail(BottomClickButton btnNext, string Email)
        {
            var sendCodePra = new SendCodePra();
            sendCodePra.Account = Email;
            bool falge = await UserCenterLogic.GetResultStatuByRequestHttps("ZigbeeUsers/LoginSendVerCode", false, sendCodePra);
            bool falge = UserCenterLogic.GetResultStatuByRequestHttps("ZigbeeUsers/RegisterSendVerCode", false, sendCodePra);
            if (falge == false)
            {
                return;
@@ -164,11 +170,11 @@
            btnNext.CanClick = false;
            //?s后重发
            string repeat = Language.StringByID(R.MyInternationalizationString.RepeatSend1);
            //有效时间300秒
            int waitime = 300;
            //有效时间60秒
            int waitime = 60;
            btnNext.Text = waitime + "s" + repeat;
            new System.Threading.Thread(() =>
            HdlThreadLogic.Current.RunThread(() =>
            {
                while (this.Parent != null)
                {
@@ -176,7 +182,6 @@
                    System.Threading.Thread.Sleep(1000);
                    if (waitime == 0)
                    {
                        this.canCheckCode = false;
                        Application.RunOnMainThread(() =>
                        {
                            if (btnNext != null)
@@ -197,8 +202,7 @@
                        }
                    });
                }
            })
            { IsBackground = true }.Start();
            });
        }
        #endregion
@@ -209,7 +213,7 @@
        /// 验证验证码
        /// </summary>
        /// <returns></returns>
        private async void CheckVerificationCode(string code)
        private void CheckVerificationCode(string code)
        {
            if (this.canCheckCode == false)
            {
@@ -222,7 +226,7 @@
            checkCodePra.Code = code;
            checkCodePra.Account = newEmail;
            bool flage = await UserCenterLogic.GetResultStatuByRequestHttps("ZigbeeUsers/ValidatorCode", false, checkCodePra);
            bool flage = UserCenterLogic.GetResultStatuByRequestHttps("ZigbeeUsers/ValidatorCode", false, checkCodePra);
            if (flage == false)
            {
                //验证码错误,请重新输入
@@ -238,12 +242,12 @@
        /// <summary>
        /// 变更邮箱
        /// </summary>
        private async void SaveNewEmail()
        private void SaveNewEmail()
        {
            var pra = new SaveNewEmailPra();
            pra.Account = this.newEmail;
            bool flage = await UserCenterLogic.GetResultStatuByRequestHttps("ZigbeeUsers/BindAccount", false, pra);
            bool flage = UserCenterLogic.GetResultStatuByRequestHttps("ZigbeeUsers/BindAccount", false, pra);
            if (flage == false)
            {
                //绑定邮箱失败