From 9d65c293924e4edbbc8c6c6091f55d7fc49c23eb Mon Sep 17 00:00:00 2001
From: wei <kaede@kaededeMacBook-Air.local>
Date: 星期二, 06 七月 2021 13:15:46 +0800
Subject: [PATCH] 乐橙子账号token
---
HDL_ON/UI/UI2/4-PersonalCenter/AccountBindInfo/ChangeBindAccountPage.cs | 129 +++++++++++++++++++++++++------------------
1 files changed, 75 insertions(+), 54 deletions(-)
diff --git a/HDL_ON/UI/UI2/4-PersonalCenter/AccountBindInfo/ChangeBindAccountPage.cs b/HDL_ON/UI/UI2/4-PersonalCenter/AccountBindInfo/ChangeBindAccountPage.cs
index 44b9478..af42f85 100644
--- a/HDL_ON/UI/UI2/4-PersonalCenter/AccountBindInfo/ChangeBindAccountPage.cs
+++ b/HDL_ON/UI/UI2/4-PersonalCenter/AccountBindInfo/ChangeBindAccountPage.cs
@@ -18,7 +18,17 @@
/// <summary>
///
/// </summary>
+ Button btnTitle;
+ /// <summary>
+ ///
+ /// </summary>
+ Button btnContent;
+
+ /// <summary>
+ ///
+ /// </summary>
Action<string> action;
+
/// <summary>
/// 鎿嶄綔鐩爣绫诲瀷 1:閭锛�2:鎵嬫満
/// </summary>
@@ -26,16 +36,8 @@
/// <summary>
/// 鏄惁涓鸿В缁戦獙璇�
/// </summary>
- public bool isUnbind;
-
- /// <summary>
- ///
- /// </summary>
- Button btnTitle;
- /// <summary>
- ///
- /// </summary>
- Button btnContent;
+ public bool IsUnbind;
+
/// <summary>
/// ChangeBindAccountPage
@@ -101,7 +103,7 @@
Y = Application.GetRealHeight(213),
Gravity = Gravity.CenterHorizontal,
Width = Application.GetRealWidth(220),
- Height = Application.GetRealHeight(44),
+ Height = Application.GetRealWidth(44),
BackgroundColor = CSS_Color.MainColor,
TextAlignment = TextAlignment.Center,
TextColor = CSS_Color.MainBackgroundColor,
@@ -148,12 +150,12 @@
{
if (optionType == 2)
{
- btnTitle.TextID = isUnbind ? StringId.CurPhone : StringId.PhoneNumberVerification;
+ btnTitle.TextID = IsUnbind ? StringId.CurPhone : StringId.PhoneNumberVerification;
btnContent.Text = UserInfo.Current.userMobileInfo;
}
else
{
- btnTitle.TextID = isUnbind ? StringId.CurrentEmail : StringId.EmailVerification;
+ btnTitle.TextID = IsUnbind ? StringId.CurrentEmail : StringId.EmailVerification;
btnContent.Text = UserInfo.Current.userEmailInfo;
}
}
@@ -184,61 +186,80 @@
{
if (button.Text == Language.StringByID(StringId.GetVerificationCode))
{
+ //鍔犺浇Loading鏁堟灉
+ var waitPage = new Loading();
+ bodyView.AddChidren(waitPage);
+ waitPage.Start(Language.StringByID(StringId.PleaseWait));
+
new Thread(() =>
{
- //1.鑾峰彇楠岃瘉鐮�,閲囩敤鏁忔劅鏁版嵁楠岃瘉
- ResponsePackNew resultObj;
- if (optionType == 1)//閭
+ try
{
- resultObj = new HttpServerRequest().VerificationCodeSend(VerifyType.SENSITIVE_DATA, UserInfo.Current.userEmailInfo);
- }
- else
- {
- resultObj = new HttpServerRequest().VerificationCodeSend(VerifyType.SENSITIVE_DATA, UserInfo.Current.userMobileInfo, true, UserInfo.Current.areaCode);
- }
-
- if (resultObj.Code != StateCode.SUCCESS)
- {
- // 鎻愮ず閿欒
- IMessageCommon.Current.ShowErrorInfoAlter(resultObj.Code);
- }
- else
- {
- if (time == 0)
+ //1.鑾峰彇楠岃瘉鐮�,閲囩敤鏁忔劅鏁版嵁楠岃瘉
+ ResponsePackNew resultObj;
+ if (optionType == 1)//閭
{
- time = 60;
- new Thread(() =>
+ resultObj = new HttpServerRequest().VerificationCodeSend(VerifyType.SENSITIVE_DATA, UserInfo.Current.userEmailInfo);
+ }
+ else
+ {
+ resultObj = new HttpServerRequest().VerificationCodeSend(VerifyType.SENSITIVE_DATA, UserInfo.Current.userMobileInfo, true, UserInfo.Current.areaCode);
+ }
+
+ if (resultObj.Code != StateCode.SUCCESS)
+ {
+ // 鎻愮ず閿欒
+ IMessageCommon.Current.ShowErrorInfoAlter(resultObj.Code);
+ }
+ else
+ {
+ if (time == 0)
{
- while (time > 0)
+ time = 60;
+ new Thread(() =>
{
- time--;
+ while (time > 0)
+ {
+ time--;
+ Application.RunOnMainThread(() =>
+ {
+ button.Text = time.ToString() + "s";
+ });
+ Thread.Sleep(1000);
+ }
Application.RunOnMainThread(() =>
{
- button.Text = time.ToString() + "s";
+ button.IsSelected = true;
+ button.TextID = StringId.GetVerificationCode;
+ button.BackgroundColor = CSS_Color.MainColor;
+ time = 0;
});
- Thread.Sleep(1000);
- }
- Application.RunOnMainThread(() =>
- {
- button.IsSelected = true;
- button.TextID = StringId.GetVerificationCode;
- button.BackgroundColor = CSS_Color.MainColor;
- time = 0;
- });
- })
- { IsBackground = true }.Start();
+ })
+ { IsBackground = true }.Start();
+ }
+ Application.RunOnMainThread(() =>
+ {
+ button.BackgroundColor = CSS_Color.PromptingColor1;
+ var vcp = new ChangeBindVerificationCodePage();
+ vcp.IsUnbind = IsUnbind;
+ MainPage.BasePageView.AddChidren(vcp);
+ vcp.LoadPage(action, titleId, optionType, time);
+ MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
+ });
}
+ }
+ catch { }
+ finally
+ {
Application.RunOnMainThread(() =>
{
- button.BackgroundColor = CSS_Color.PromptingColor1;
- var vcp = new ChangeBindVerificationCodePage();
- vcp.isUnbind = isUnbind;
- MainPage.BasePageView.AddChidren(vcp);
- vcp.LoadPage(action, titleId, optionType, time);
- MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
+ if (waitPage != null)
+ {
+ waitPage.RemoveFromParent();
+ waitPage = null;
+ }
});
}
-
})
{ IsBackground = true }.Start();
}
--
Gitblit v1.8.0