diff --git a/App.xaml b/App.xaml index 4591e2a..3c99c29 100644 --- a/App.xaml +++ b/App.xaml @@ -15,7 +15,7 @@ xmlns:settingPages="clr-namespace:SparkClient.Views.Configuration.SettingPages" xmlns:configuration="clr-namespace:System.Configuration;assembly=System.Configuration.ConfigurationManager" xmlns:sparkClient="clr-namespace:SparkClient" - StartupUri="MainWindow.xaml"> + StartupUri="LoginWindow.xaml"> diff --git a/App.xaml.cs b/App.xaml.cs index c2129ac..532adfa 100644 --- a/App.xaml.cs +++ b/App.xaml.cs @@ -6,6 +6,7 @@ using System.Windows.Media; using System.Windows.Threading; using log4net.Config; using SparkClient.Model.Helper; +using SparkClient.ViewModel.Configuration.SettingsPages; namespace SparkClient; @@ -23,6 +24,12 @@ public partial class App : Application Log4NetHelper.ArchiveOldLogs(); //打开数据库连接 //读取数据库多语言配置 - + DataBaseHelper.CreateConnection(); + string LanguageId = Settings.SelectValueByName("LanguageId"); + if (LanguageId.Length == 0) + { + LanguageId = "zh-cn"; + } + MultilingualHelper.setLanguage(LanguageId); } } \ No newline at end of file diff --git a/Language/zh_CN.xaml b/Language/zh_CN.xaml index 1df8ea7..e46a666 100644 --- a/Language/zh_CN.xaml +++ b/Language/zh_CN.xaml @@ -23,7 +23,7 @@ 算法配置 定级配置 切工仪配置 - + 用户名或密码错误,请重试 删除配置 导入配置 diff --git a/LoginWindow.xaml b/LoginWindow.xaml index 8bc5b38..6f57c7f 100644 --- a/LoginWindow.xaml +++ b/LoginWindow.xaml @@ -67,7 +67,7 @@ @@ -85,20 +85,20 @@ - + hc:InfoElement.Placeholder="{StaticResource LoginWindowPassword}" /> -