Ver a proveniência

消息日志修改

样式分支
pry há 2 anos
ascendente
cometimento
1c5abf3484
2 ficheiros alterados com 35 adições e 1 eliminações
  1. +34
    -0
      BPASmartClient.CustomResource/Pages/ViewModel/MainViewModel.cs
  2. +1
    -1
      BPASmartClient.JXJFoodSmallStation/App.xaml.cs

+ 34
- 0
BPASmartClient.CustomResource/Pages/ViewModel/MainViewModel.cs Ver ficheiro

@@ -20,6 +20,40 @@ namespace BPASmartClient.CustomResource.Pages.ViewModel
public MainViewModel()
{
NavChangedCommand = new RelayCommand<object>(DoNavChanged);
BPASmartClient.Message. MessageLog.GetInstance.InfoNotify = new Action<string>((o) =>
{
Application.Current?.Dispatcher?.Invoke(() =>
{
//ff20aefe
var temp = new MessageModel()
{
LogInfo = o,
Forground = new SolidColorBrush(Color.FromArgb(255, 32, 174, 254))
};
if (DebugLogViewModel.MessageModels.Count > 0)
DebugLogViewModel.MessageModels.Insert(0, temp);
else
DebugLogViewModel.MessageModels.Add(temp);
});
});

BPASmartClient.Message.MessageLog.GetInstance.ExInfoNotify = new Action<string>((o) =>
{
Application.Current?.Dispatcher?.Invoke(() =>
{
//FFF53F62
var temp = new MessageModel()
{
LogInfo = o,
Forground = new SolidColorBrush(Color.FromArgb(255, 245, 63, 98))
};
if (DebugLogViewModel.MessageModels.Count > 0)
DebugLogViewModel.MessageModels.Insert(0, temp);
else
DebugLogViewModel.MessageModels.Add(temp);
});
});

BPA.Helper.MessageLog.GetInstance.NotifyShow = new Action<string>((o) =>
{
Application.Current?.Dispatcher?.Invoke(() =>


+ 1
- 1
BPASmartClient.JXJFoodSmallStation/App.xaml.cs Ver ficheiro

@@ -29,8 +29,8 @@ namespace BPASmartClient.JXJFoodSmallStation
MenuInit();
DataInit();
//DeviceInquire.GetInstance.Init();//配料机设备上线监听,设备列表初始化
ProcessControl.GetInstance.Init();
MainView mv = new MainView();
ProcessControl.GetInstance.Init();
LoginView lv = new LoginView();
var res = lv.ShowDialog();
if (res != null && res == true)


Carregando…
Cancelar
Guardar