From 28d269d8aa90eca5470fff825a9b9545135a3ec0 Mon Sep 17 00:00:00 2001
From: 黄学彪 <hxb@hdlchina.com.cn>
Date: 星期三, 16 十二月 2020 17:37:26 +0800
Subject: [PATCH] 上传一个初始版本

---
 HDL_ON/UI/UI2/4-PersonalCenter/UnlockSetting/AppUnlockPasswordPage.cs |   74 +++++++++----------------------------
 1 files changed, 18 insertions(+), 56 deletions(-)

diff --git a/HDL_ON/UI/UI2/4-PersonalCenter/UnlockSetting/AppUnlockPasswordPage.cs b/HDL_ON/UI/UI2/4-PersonalCenter/UnlockSetting/AppUnlockPasswordPage.cs
index 9ce773d..e94eb79 100644
--- a/HDL_ON/UI/UI2/4-PersonalCenter/UnlockSetting/AppUnlockPasswordPage.cs
+++ b/HDL_ON/UI/UI2/4-PersonalCenter/UnlockSetting/AppUnlockPasswordPage.cs
@@ -437,68 +437,30 @@
                 //杈撳叆鐧诲綍瀵嗙爜楠岃瘉
                 Action<string> action = (pw) =>
                 {
-                    AuthenticationByLoginPassword(pw, optionType);
-                    //var resultObj = new HttpServerRequest().LoginByPassword(UserInfo.Current.AccountString, pw);
-                    //if (resultObj.Code == StateCode.SUCCESS)
-                    //{
-                    //    PasswordInputPassed(optionType);
-                    //}
-                    //else
-                    //{
-                    //    Application.RunOnMainThread(() =>
-                    //    {
-                    //        Utlis.ShowTip(Language.StringByID(StringId.AuthenticationFailedPasswordError));
-                    //    });
+                    var resultObj = new HttpServerRequest().LoginByPassword(UserInfo.Current.AccountString, pw);
+                    if (resultObj.Code.ToUpper() == StateCode.SUCCESS)
+                    {
+                        //UserInfo.Current.appUnlockPasswrod = "";
+                        //UserInfo.Current.appUnlockType = new System.Collections.Generic.List<string>();
+                        //UserInfo.Current.SaveUserInfo();
+                        //this.RemoveFromParent();
+                        //backAction();
 
-                    //}
+                        PasswordInputPassed(optionType);
+                    }
+                    else
+                    {
+                        Application.RunOnMainThread(() =>
+                        {
+                            Utlis.ShowTip(Language.StringByID(StringId.AuthenticationFailedPasswordError));
+                        });
+
+                    }
 
                 };
                 new PublicAssmebly().LoadDialog_EditParater(StringId.EnterLoginPasswordVerification, "", action, StringId.PlsEntryPassword, 0, new System.Collections.Generic.List<string>(), true);
             };
         }
 
-        /// <summary>
-        /// 鐧诲綍瀵嗙爜楠岃瘉
-        /// </summary>
-        /// <param name="pw"></param>
-        /// <param name="optionType"></param>
-        void AuthenticationByLoginPassword(string pw, string optionType)
-        {
-            var waitPage = new Loading();
-            bodyView.AddChidren(waitPage);
-            waitPage.Start(Language.StringByID(StringId.PleaseWait));
-
-            new System.Threading.Thread(() =>
-            {
-                try
-                {
-                    var resultObj = new HttpServerRequest().LoginByPassword(UserInfo.Current.AccountString, pw);
-                    Application.RunOnMainThread(() =>
-                    {
-                        if (resultObj.Code == StateCode.SUCCESS)
-                        {
-                            PasswordInputPassed(optionType);
-                        }
-                        else
-                        {
-                            Utlis.ShowTip(Language.StringByID(StringId.AuthenticationFailedPasswordError));
-                        }
-                    });
-                }
-                catch { }
-                finally
-                {
-                    Application.RunOnMainThread(() =>
-                    {
-                        if (waitPage != null)
-                        {
-                            waitPage.RemoveFromParent();
-                            waitPage = null;
-                        }
-                    });
-                }
-            })
-            { IsBackground = true }.Start();
-        }
     }
 }

--
Gitblit v1.8.0