将NlogHelper,和NotificationHelper,改为服务的方式注入使用

This commit is contained in:
2025-09-04 17:29:24 +08:00
parent c45287fae0
commit bb650e2682
35 changed files with 307 additions and 474 deletions

View File

@@ -1,5 +1,4 @@
using System.Windows;
using DMS.Core.Helper;
using DMS.WPF.Services;
using DMS.WPF.ViewModels;
using iNKORE.UI.WPF.Modern.Controls;
@@ -23,8 +22,7 @@ public partial class MainView : Window
InitializeComponent();
_viewModel = App.Current.Services.GetRequiredService<MainViewModel>();
DataContext = _viewModel;
NlogHelper.Info("主界面加载成功");
// Set the NotifyIcon's DataContext to the ViewModel
MyNotifyIcon.DataContext = _viewModel;
}