| | |
| | | using DevExpress.LookAndFeel; |
| | | using HStation.DeskTop; |
| | | using DevExpress.XtraEditors.Controls; |
| | | using Mapster; |
| | | using System; |
| | | using System.Reflection; |
| | |
| | | DevExpress.XtraEditors.WindowsFormsSettings.DefaultMenuFont = font; |
| | | DevExpress.Utils.AppearanceObject.DefaultFont = font; |
| | | |
| | | DevExpress.XtraEditors.Controls.Localizer.Active = new XtraMessBoxClass(); |
| | | //zh-Hans界面翻译 |
| | | System.Threading.Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo("zh-Hans"); |
| | | System.Threading.Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo("zh-Hans"); |
| | |
| | | var loginHelper = new LoginHelper(); |
| | | if (!loginHelper.Login()) |
| | | return; |
| | | var result = HStation.Service.Organize.DbFirstHelper.Initial(out string msg); |
| | | Yw.BLL.AuthDbFirstHelper authDbFirstHelper = new Yw.BLL.AuthDbFirstHelper(); |
| | | authDbFirstHelper.Initial(); |
| | | // var result_phart = HStation.Service.Phart.DbFirstHelper.Initial(out msg); |
| | | Application.Run(new GuideMain()); |
| | | } |
| | | } |
| | |
| | | Yw.LogHelper.Error("系统出现未知异常,ERROR:255", ex); |
| | | MessageBox.Show($"系统出现未知异常,请重启系统!\r\n{ex.Message}"); |
| | | } |
| | | |
| | | |
| | | public class XtraMessBoxClass : Localizer |
| | | { |
| | | public override string GetLocalizedString(DevExpress.XtraEditors.Controls.StringId id) |
| | | { |
| | | switch (id) |
| | | { |
| | | case StringId.XtraMessageBoxCancelButtonText: |
| | | return "取消"; |
| | | |
| | | case StringId.XtraMessageBoxOkButtonText: |
| | | return "确定"; |
| | | |
| | | case StringId.XtraMessageBoxYesButtonText: |
| | | return "是"; |
| | | |
| | | case StringId.XtraMessageBoxNoButtonText: |
| | | return "否"; |
| | | |
| | | case StringId.XtraMessageBoxIgnoreButtonText: |
| | | return "忽略"; |
| | | |
| | | case StringId.XtraMessageBoxAbortButtonText: |
| | | return "中止"; |
| | | |
| | | case StringId.XtraMessageBoxRetryButtonText: |
| | | return "重试"; |
| | | |
| | | default: |
| | | return base.GetLocalizedString(id); |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | | } |