From 3f6685c77beeb12baf840733fb890860f4c26e7c Mon Sep 17 00:00:00 2001
From: mac <user@users-MacBook-Pro.local>
Date: 星期四, 25 七月 2024 17:25:59 +0800
Subject: [PATCH] 2024年07月25日17:24:45

---
 HDL_ON/UI/UI1-Login/LoginPageBLL.cs |   54 +++++++++++++++++++++++++++---------------------------
 1 files changed, 27 insertions(+), 27 deletions(-)

diff --git a/HDL_ON/UI/UI1-Login/LoginPageBLL.cs b/HDL_ON/UI/UI1-Login/LoginPageBLL.cs
index 34968ff..90e8660 100644
--- a/HDL_ON/UI/UI1-Login/LoginPageBLL.cs
+++ b/HDL_ON/UI/UI1-Login/LoginPageBLL.cs
@@ -230,6 +230,9 @@
                     }
                     //楠岃瘉鐮佷笉闇�瑕侀殣钘�
                     etPassword.SecureTextEntry = false;
+#if __IOS__
+                    etPassword.SetTextContentTypeToOneTimeCode();
+#endif
                 }
                 #endregion
             }
@@ -318,7 +321,7 @@
                 //}
                 //闅愯棌瀵嗙爜
                 etPassword.SecureTextEntry = true;
-                etPassword.IsNumberKeyboardType = false;
+                //etPassword.IsNumberKeyboardType = false;
             }
             //楠岃瘉鐮佺櫥褰�
             else if (logintMode == 1)
@@ -347,23 +350,8 @@
                 //楠岃瘉鐮佷笉闇�瑕侀殣钘�
                 etPassword.SecureTextEntry = false;
                 etPassword.Text = smsCode;
-                etPassword.IsNumberKeyboardType = true;
-#if __IOS__
-                var currentInputMode = UIKit.UITextInputMode.CurrentInputMode;
-                var installedInputModes = UIKit.UITextInputMode.ActiveInputModes;
-                var temmm = new EditText()
-                {
-                    X = Application.GetRealWidth(78),
-                    Width = Application.GetRealWidth(61 + 84),
-                    TextColor = CSS_Color.FirstLevelTitleColor,
-                    TextSize = CSS_FontSize.TextFontSize,
-                    TextAlignment = TextAlignment.CenterLeft,
-                    Foucs = true,
-                    BackgroundColor  = 0x44330000,
-                };
-                passwordView.AddChidren(etPassword); 
+                //etPassword.IsNumberKeyboardType = true;
 
-#endif
             }
         }
 
@@ -457,16 +445,23 @@
                 {
                     btnPasswordViewBottomLine.BackgroundColor = CSS_Color.MainColor;
                     btnPasswordViewBottomLine.Height = Application.GetRealHeight(2);
-                    new Thread(() => {
-                        for(var i = 0; i < 10; i++)
-                        {
-                            Application.RunOnMainThread(() =>
+
+#if __IOS__
+      new Thread(() => {
+                            for(var i = 0; i < 10; i++)
                             {
-                                this.Y = 0-Application.GetRealHeight(10 * i);
-                            });
-                            Thread.Sleep(10);
-                        }
-                    }) { IsBackground = true }.Start();
+                                Application.RunOnMainThread(() =>
+                                {
+                                    this.Y = 0-Application.GetRealHeight(10 * i);
+                                });
+                                Thread.Sleep(10);
+                            }
+                        }) { IsBackground = true }.Start();
+
+                    var sst = etPassword.MyTextContentType;
+                    Console.WriteLine(sst);
+                    etPassword.SetTextContentTypeToOneTimeCode();
+#endif
                 }
                 else
                 {
@@ -484,8 +479,8 @@
             //褰撶劍鐐瑰湪瀵嗙爜鏂囨湰妗嗘椂锛岀偣鍑婚敭鐩樺洖鎾ゆ寜閿紝瑙﹀彂鐨勪簨浠�
             etPassword.EditorEnterAction += (obj) =>
             {
-                LoginEvent();
                 Application.HideSoftInput();
+                LoginEvent();
             };
         }
 
@@ -735,6 +730,11 @@
                 //璋冪敤楠岃瘉鐮佺櫥褰曟帴鍙�
                 loginResult = pm.LoginValidCode(account, password);
             }
+            if(loginResult == null)
+            {
+
+                return false;
+            }
             if (loginResult.Code == StateCode.SUCCESS)
             {
                 var revertData = Newtonsoft.Json.JsonConvert.DeserializeObject<UserLoginRes>(loginResult.Data.ToString());

--
Gitblit v1.8.0