fyf преди 2 години
родител
ревизия
418a6d8b3d
променени са 2 файла, в които са добавени 6 реда и са изтрити 10 реда
  1. +4
    -6
      BPASmartClient.ViewModel/LogOrAlarmViewModel.cs
  2. +2
    -4
      BPASmartClient/Control/LogOrAlarmView.xaml

+ 4
- 6
BPASmartClient.ViewModel/LogOrAlarmViewModel.cs Целия файл

@@ -128,13 +128,11 @@ namespace BPASmartClient.ViewModel
LogDataGrid = new ObservableCollection<LogModel>();
DateTimeStr = DateTime.Now;
BookExs.Add(new BookEx(new Book() { Name = "一般日志条件", Tag = "Info" }) { IsChecked = true });
BookExs.Add(new BookEx(new Book() { Name = "设备日志条件", Tag = "DeviceLog" }));
BookExs.Add(new BookEx(new Book() { Name = "错误日志条件", Tag = "Error" }));
BookExs.Add(new BookEx(new Book() { Name = "设备告警条件", Tag = "DeviceAlarm" }));
SelectedText = "一般日志条件";
BookExs.Add(new BookEx(new Book() { Name = "设备日志条件", Tag = "DeviceLog" }) { IsChecked = true });
BookExs.Add(new BookEx(new Book() { Name = "错误日志条件", Tag = "Error" }) { IsChecked = true });
BookExs.Add(new BookEx(new Book() { Name = "设备告警条件", Tag = "DeviceAlarm" }) { IsChecked = true });
SelectBookExs = new ObservableCollection<BookEx>();
SelectBookExs.Add(new BookEx(new Book() { Name = "一般日志条件", Tag = "Info" }) { IsChecked = true });

ItemPropertyChanged(new BookEx(new Book() { Name = "一般日志条件", Tag = "Info" }) { IsChecked = true },new PropertyChangedEventArgs("IsChecked"));
//查询
QueryCommand = new RelayCommand(() =>
{


+ 2
- 4
BPASmartClient/Control/LogOrAlarmView.xaml Целия файл

@@ -26,12 +26,10 @@

<!-- 查询按钮栏 -->
<StackPanel Margin="10,0,10,0" Orientation="Horizontal">
<ComboBox Width="120" Text="{Binding SelectedText}" IsEditable="True" ItemsSource="{Binding Path=BookExs}">
<ComboBox Width="120" Text="{Binding SelectedText}" IsEditable="True" ItemsSource="{Binding Path=BookExs}">
<ComboBox.ItemTemplate>
<DataTemplate DataType="{x:Type k:BookEx}">
<StackPanel Orientation="Horizontal">
<CheckBox IsChecked="{Binding IsChecked}" Margin="2,0,3,0" Background="Red" Content="{Binding BookN.Name}" />
</StackPanel>
<CheckBox Width="110" IsChecked="{Binding IsChecked}" Content="{Binding BookN.Name}" />
</DataTemplate>
</ComboBox.ItemTemplate>
</ComboBox>


Зареждане…
Отказ
Запис