diff --git a/src/ST.Client.Desktop.Avalonia/Application/UI/Views/Windows/LocalAuthPage/ExportAuthWindow.axaml b/src/ST.Client.Desktop.Avalonia/Application/UI/Views/Windows/LocalAuthPage/ExportAuthWindow.axaml
index 44b981401..5b01b94e4 100644
--- a/src/ST.Client.Desktop.Avalonia/Application/UI/Views/Windows/LocalAuthPage/ExportAuthWindow.axaml
+++ b/src/ST.Client.Desktop.Avalonia/Application/UI/Views/Windows/LocalAuthPage/ExportAuthWindow.axaml
@@ -42,7 +42,7 @@
-
+
@@ -50,11 +50,11 @@
-
+
-
+
diff --git a/src/ST.Client.Desktop/Services/Mvvm/AuthService.cs b/src/ST.Client.Desktop/Services/Mvvm/AuthService.cs
index 8ea41807e..981c25555 100644
--- a/src/ST.Client.Desktop/Services/Mvvm/AuthService.cs
+++ b/src/ST.Client.Desktop/Services/Mvvm/AuthService.cs
@@ -67,11 +67,19 @@ namespace System.Application.Services
//else
// ToastService.Current.Notify(AppResources.LocalAuth_RefreshAuthSuccess);
}
+ else if (auths.Any_Nullable() && !list.Any_Nullable())
+ {
+ Toast.Show(AppResources.LocalAuth_ProtectionAuth_PasswordError);
+ }
}
public async Task HasPasswordEncryptionShowPassWordWindow()
{
var auths = await repository.GetAllSourceAsync();
+ if (!auths.Any_Nullable())
+ {
+ return false;
+ }
var hasPassword = repository.HasSecondaryPassword(auths);
if (hasPassword)
{
@@ -81,6 +89,7 @@ namespace System.Application.Services
{
return true;
}
+ Toast.Show(AppResources.LocalAuth_ProtectionAuth_PasswordError);
return false;
}
else
diff --git a/src/ST.Client.Desktop/UI/Resx/AppResources.Designer.cs b/src/ST.Client.Desktop/UI/Resx/AppResources.Designer.cs
index 258d189b3..eb1523b91 100644
--- a/src/ST.Client.Desktop/UI/Resx/AppResources.Designer.cs
+++ b/src/ST.Client.Desktop/UI/Resx/AppResources.Designer.cs
@@ -1917,6 +1917,15 @@ namespace System.Application.UI.Resx {
}
}
+ ///
+ /// 查找类似 密码错误 的本地化字符串。
+ ///
+ public static string LocalAuth_ProtectionAuth_PasswordError {
+ get {
+ return ResourceManager.GetString("LocalAuth_ProtectionAuth_PasswordError", resourceCulture);
+ }
+ }
+
///
/// 查找类似 请输入正确的密码 的本地化字符串。
///
diff --git a/src/ST.Client.Desktop/UI/Resx/AppResources.resx b/src/ST.Client.Desktop/UI/Resx/AppResources.resx
index c12a83ed2..c2a29d400 100644
--- a/src/ST.Client.Desktop/UI/Resx/AppResources.resx
+++ b/src/ST.Client.Desktop/UI/Resx/AppResources.resx
@@ -741,6 +741,9 @@
自定义密码
+
+ 密码错误
+
请输入正确的密码
diff --git a/src/ST.Client.Desktop/UI/ViewModels/Windows/LocalAuthPage/EncryptionAuthWindowViewModel.cs b/src/ST.Client.Desktop/UI/ViewModels/Windows/LocalAuthPage/EncryptionAuthWindowViewModel.cs
index f9928a622..0ffb75182 100644
--- a/src/ST.Client.Desktop/UI/ViewModels/Windows/LocalAuthPage/EncryptionAuthWindowViewModel.cs
+++ b/src/ST.Client.Desktop/UI/ViewModels/Windows/LocalAuthPage/EncryptionAuthWindowViewModel.cs
@@ -25,8 +25,8 @@ namespace System.Application.UI.ViewModels
IsOnlyCurrentComputerEncrypt = repository.HasLocal(auths);
if (IsPasswordEncrypt)
{
- Password = "******";
- VerifyPassword = "******";
+ //Password = "******";
+ //VerifyPassword = "******";
}
}