创建系统状态表、当前工作设备表及当前故障设备表及数据中心布局
This commit is contained in:
parent
6ca627a1ac
commit
6d7a514d3a
@ -0,0 +1,66 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace InSituLaboratory.Entities.ExperimentalStationEntities
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 当前故障设备 0-正常 1-故障
|
||||||
|
/// </summary>
|
||||||
|
public class CurrentFaultyEquipment
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// ID
|
||||||
|
/// </summary>
|
||||||
|
[Key]
|
||||||
|
public int Id { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 采样时间
|
||||||
|
/// </summary>
|
||||||
|
public DateTime? SamplingTime { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建时间
|
||||||
|
/// </summary>
|
||||||
|
public DateTime? CreateTime { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// MEMS色谱仪
|
||||||
|
/// </summary>
|
||||||
|
public string? Chromatograph_MEMS { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// MEMS质谱仪
|
||||||
|
/// </summary>
|
||||||
|
public string? MassSpectrometer_MEMS { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 色质联用仪
|
||||||
|
/// </summary>
|
||||||
|
public string? ColorMassSpectrometer { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 甲烷同位素分析仪
|
||||||
|
/// </summary>
|
||||||
|
public string? CH4Analyzer { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 二氧化碳同位素分析仪
|
||||||
|
/// </summary>
|
||||||
|
public string? CO2Analyzer { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 颗粒物分析仪
|
||||||
|
/// </summary>
|
||||||
|
public string? ParticleAnalyzer { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 测序仪
|
||||||
|
/// </summary>
|
||||||
|
public string? Sequencer { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,66 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace InSituLaboratory.Entities.ExperimentalStationEntities
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 当前工作设备 0-待机 1-工作
|
||||||
|
/// </summary>
|
||||||
|
public class CurrentWorkEquipment
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// ID
|
||||||
|
/// </summary>
|
||||||
|
[Key]
|
||||||
|
public int Id { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 采样时间
|
||||||
|
/// </summary>
|
||||||
|
public DateTime? SamplingTime { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建时间
|
||||||
|
/// </summary>
|
||||||
|
public DateTime? CreateTime { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// MEMS色谱仪
|
||||||
|
/// </summary>
|
||||||
|
public string? Chromatograph_MEMS { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// MEMS质谱仪
|
||||||
|
/// </summary>
|
||||||
|
public string? MassSpectrometer_MEMS { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 色质联用仪
|
||||||
|
/// </summary>
|
||||||
|
public string? ColorMassSpectrometer { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 甲烷同位素分析仪
|
||||||
|
/// </summary>
|
||||||
|
public string? CH4Analyzer { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 二氧化碳同位素分析仪
|
||||||
|
/// </summary>
|
||||||
|
public string? CO2Analyzer { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 颗粒物分析仪
|
||||||
|
/// </summary>
|
||||||
|
public string? ParticleAnalyzer { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 测序仪
|
||||||
|
/// </summary>
|
||||||
|
public string? Sequencer { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,119 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace InSituLaboratory.Entities.ExperimentalStationEntities
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 系统状态
|
||||||
|
/// </summary>
|
||||||
|
public class SysStatus
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// ID
|
||||||
|
/// </summary>
|
||||||
|
[Key]
|
||||||
|
public int Id { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 组包时间
|
||||||
|
/// </summary>
|
||||||
|
public DateTime? PackagingTime { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 采样时间
|
||||||
|
/// </summary>
|
||||||
|
public DateTime? SamplingTime { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建时间
|
||||||
|
/// </summary>
|
||||||
|
public DateTime? CreateTime { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 48V 电压
|
||||||
|
/// </summary>
|
||||||
|
public float? Voltage48 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 48V 电流
|
||||||
|
/// </summary>
|
||||||
|
public float? Current48 { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 基站48V漏电流状态 第0位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? BaseStation48VLeakageCS { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 电池48V漏电流状态 第2位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? Batterz48VLeakageCS { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// ICL漏电流状态 第4位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? ICLLeakageCS { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 工控机漏电流状态 第6位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? IComputerLeakageCS { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 温度1状态 第8位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? TemperatureStaus1 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 温度2状态 第10位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? TemperatureStaus2 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 湿度1状态 第12位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? HumidityStaus1 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 湿度2状态 第14位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? HumidityStaus2 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 漏水1状态 第16位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? LeakageStaus1 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 漏水2状态 第18位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? LeakageStaus2 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 内部压力1状态 第20位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? InternalPressure1 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 内部压力2状态 第22位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
|
||||||
|
/// </summary>
|
||||||
|
public string? InternalPressure2 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 时序组号
|
||||||
|
/// </summary>
|
||||||
|
public string? TimeSeriesGroupNumber { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 时序状态 0表示保持,1表示成功,2表示错误
|
||||||
|
/// </summary>
|
||||||
|
public string? GroupNumberStatus { get; set; }
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
18
InSituLaboratory.Models/BoardModel.cs
Normal file
18
InSituLaboratory.Models/BoardModel.cs
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace InSituLaboratory.Models
|
||||||
|
{
|
||||||
|
public class BoardModel
|
||||||
|
{
|
||||||
|
public string Icon { get; set; }
|
||||||
|
public string Header { get; set; }
|
||||||
|
public double Value { get; set; }
|
||||||
|
public string Flag { get; set; }
|
||||||
|
public double GrowingRate { get; set; }
|
||||||
|
public string Color { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -1,5 +1,6 @@
|
|||||||
|
|
||||||
using InSituLaboratory.Entities;
|
using InSituLaboratory.Entities;
|
||||||
|
using InSituLaboratory.Entities.ExperimentalStationEntities;
|
||||||
using Microsoft.EntityFrameworkCore;
|
using Microsoft.EntityFrameworkCore;
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
@ -69,5 +70,8 @@ namespace InSituLaboratory.ORM
|
|||||||
public virtual DbSet<SysSequentialDetails> SysSequentialDetails { get; set; }
|
public virtual DbSet<SysSequentialDetails> SysSequentialDetails { get; set; }
|
||||||
public virtual DbSet<SysDevice> SysDevice { get; set; }
|
public virtual DbSet<SysDevice> SysDevice { get; set; }
|
||||||
public virtual DbSet<SysSequentialTotal> SysSequentialTotal { get; set; }
|
public virtual DbSet<SysSequentialTotal> SysSequentialTotal { get; set; }
|
||||||
|
public virtual DbSet<CurrentFaultyEquipment> CurrentFaultyEquipment { get; set; }
|
||||||
|
public virtual DbSet<CurrentWorkEquipment> CurrentWorkEquipment { get; set; }
|
||||||
|
public virtual DbSet<SysStatus> SysStatus { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -8,28 +8,20 @@ using System.Linq;
|
|||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using InSituLaboratory.Models;
|
using InSituLaboratory.Models;
|
||||||
|
using InSituLaboratory.Entities.ExperimentalStationEntities;
|
||||||
|
|
||||||
namespace InSituLaboratory.ViewModels.Pages
|
namespace InSituLaboratory.ViewModels.Pages
|
||||||
{
|
{
|
||||||
public class DashboardViewModel : ViewModelBase
|
public class DashboardViewModel : ViewModelBase
|
||||||
{
|
{
|
||||||
public ObservableCollection<MEMSChromatogramModel> MEMSList { get; set; } = new ObservableCollection<MEMSChromatogramModel>();
|
public ObservableCollection<SysStatus> SysStatusList { get; set; } = new ObservableCollection<SysStatus>();
|
||||||
public ObservableCollection<MEMSMassModel> MEMSMassList { get; set; } = new ObservableCollection<MEMSMassModel>();
|
|
||||||
public DashboardViewModel() : base(null)
|
public DashboardViewModel() : base(null)
|
||||||
{
|
{
|
||||||
PageTitle = "数据中心";
|
PageTitle = "数据中心";
|
||||||
IsCanClose = false;
|
IsCanClose = false;
|
||||||
|
|
||||||
MEMSList.Add(new MEMSChromatogramModel { SamplingTime = DateTime.Now, FaultCodes = "设备温度:正常;湿度:正常", C2Concentration = "30" , C3Concentration="40" , C4Concentration ="50"});
|
|
||||||
MEMSList.Add(new MEMSChromatogramModel { SamplingTime = DateTime.Now, FaultCodes = "压力:警报、绝缘:未监控", C2Concentration = "10" , C3Concentration="20" , C4Concentration ="30"});
|
|
||||||
|
|
||||||
MEMSList.Add(new MEMSChromatogramModel { SamplingTime = DateTime.Now, FaultCodes = "设备温度:正常;湿度:正常", C2Concentration = "20" , C3Concentration="30" , C4Concentration ="70"});
|
|
||||||
MEMSList.Add(new MEMSChromatogramModel { SamplingTime = DateTime.Now, FaultCodes = "湿度:正常", C2Concentration = "15" , C3Concentration="20" , C4Concentration ="30"});
|
|
||||||
MEMSList.Add(new MEMSChromatogramModel { SamplingTime = DateTime.Now, FaultCodes = "压力:正常", C2Concentration = "15" , C3Concentration="20" , C4Concentration ="30"});
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
MEMSMassList.Add(new MEMSMassModel { SamplingTime = DateTime.Now, FaultCodes = "压力:正常", CH4Concentration = "10", H2OConcentration="20" , N2Concentration ="30", O2Concentration ="40", ARConcentration ="50", CO2Concentration ="60"});
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -7,191 +7,47 @@
|
|||||||
mc:Ignorable="d"
|
mc:Ignorable="d"
|
||||||
FontFamily="{StaticResource DigitalDisplay}"
|
FontFamily="{StaticResource DigitalDisplay}"
|
||||||
d:DesignHeight="450" d:DesignWidth="800">
|
d:DesignHeight="450" d:DesignWidth="800">
|
||||||
<ScrollViewer>
|
<ScrollViewer Margin="0,5,0,10">
|
||||||
<Grid Margin="10,20">
|
<Grid>
|
||||||
<Grid.RowDefinitions>
|
<Grid.RowDefinitions>
|
||||||
<RowDefinition Height="auto"/>
|
<RowDefinition Height="auto"/>
|
||||||
<RowDefinition Height="auto"/>
|
<RowDefinition Height="auto"/>
|
||||||
<RowDefinition Height="auto"/>
|
<RowDefinition Height="auto"/>
|
||||||
<RowDefinition Height="auto"/>
|
<RowDefinition Height="auto"/>
|
||||||
|
<RowDefinition Height="auto"/>
|
||||||
</Grid.RowDefinitions>
|
</Grid.RowDefinitions>
|
||||||
|
|
||||||
<Grid Grid.Row="1">
|
<!--第二行-->
|
||||||
<!--第一列-->
|
<ItemsControl ItemsSource="{Binding BoardList}">
|
||||||
|
<ItemsControl.ItemsPanel>
|
||||||
|
<ItemsPanelTemplate>
|
||||||
|
<UniformGrid Rows="1"/>
|
||||||
|
</ItemsPanelTemplate>
|
||||||
|
</ItemsControl.ItemsPanel>
|
||||||
|
<ItemsControl.ItemTemplate>
|
||||||
|
<DataTemplate>
|
||||||
<Border CornerRadius="5" Background="#FAFCFF" Margin="10">
|
<Border CornerRadius="5" Background="#FAFCFF" Margin="10">
|
||||||
<Border.Effect>
|
<Border.Effect>
|
||||||
<DropShadowEffect BlurRadius="10" ShadowDepth="0" Direction="0" Color="#555" Opacity="0.1"/>
|
<DropShadowEffect BlurRadius="10" ShadowDepth="0"
|
||||||
|
Color="#555" Opacity="0.1"/>
|
||||||
</Border.Effect>
|
</Border.Effect>
|
||||||
</Border>
|
<StackPanel Margin="30,10">
|
||||||
<Grid Background="#FAFCFF" Margin="20">
|
<TextBlock Foreground="#AAA" Margin="0,10,0,5" FontSize="12">
|
||||||
<Grid.RowDefinitions>
|
<Run Text="{Binding Icon}" FontFamily="{StaticResource Icons}" Foreground="{Binding Color}" FontSize="15"/>
|
||||||
<RowDefinition Height="45"/>
|
<Run Text="{Binding Header}"/>
|
||||||
<RowDefinition/>
|
</TextBlock>
|
||||||
</Grid.RowDefinitions>
|
|
||||||
<!--列头-->
|
|
||||||
<Border Background="#EFEFEF" Height="1" VerticalAlignment="Bottom"/>
|
|
||||||
<TextBlock Text="MEMS色谱仪" FontSize="14" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="15,0" FontWeight="Normal" />
|
|
||||||
|
|
||||||
<Grid Grid.Row="1">
|
<TextBlock Text="{Binding Value,StringFormat={}{0:N0}}" FontSize="22" FontWeight="Normal" Foreground="#555"/>
|
||||||
<Grid.RowDefinitions>
|
|
||||||
<RowDefinition/>
|
<Grid Margin="0,5,0,10" TextBlock.FontSize="11">
|
||||||
<RowDefinition/>
|
<TextBlock HorizontalAlignment="Left" Foreground="Green">
|
||||||
</Grid.RowDefinitions>
|
</TextBlock>
|
||||||
<Grid Grid.Row="0" TextBlock.FontSize="12" TextBlock.FontWeight="Bold" TextBlock.Foreground="#666" Margin="0,10">
|
|
||||||
<Grid.ColumnDefinitions>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
</Grid.ColumnDefinitions>
|
|
||||||
<TextBlock Text="采样时间" VerticalAlignment="Center" HorizontalAlignment="Center"/>
|
|
||||||
<TextBlock Text="故障代码" Grid.Column="1" VerticalAlignment="Center" HorizontalAlignment="Center"/>
|
|
||||||
<TextBlock Text="C2浓度" Grid.Column="2" VerticalAlignment="Center" Margin="5,0"/>
|
|
||||||
<TextBlock Text="C3浓度" Grid.Column="3" VerticalAlignment="Center" Margin="5,0"/>
|
|
||||||
<TextBlock Text="C4浓度" Grid.Column="4" VerticalAlignment="Center" Margin="5,0"/>
|
|
||||||
</Grid>
|
|
||||||
<ListBox Grid.Row="1" Background="Transparent" BorderThickness="0" ItemsSource="{Binding MEMSList}">
|
|
||||||
<ListBox.ItemContainerStyle>
|
|
||||||
<Style TargetType="ListBoxItem">
|
|
||||||
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
|
|
||||||
<Setter Property="Template">
|
|
||||||
<Setter.Value>
|
|
||||||
<ControlTemplate TargetType="ListBoxItem">
|
|
||||||
<Border Background="Transparent" Name="border">
|
|
||||||
<ContentPresenter/>
|
|
||||||
</Border>
|
|
||||||
<ControlTemplate.Triggers>
|
|
||||||
<Trigger Property="IsMouseOver" Value="True">
|
|
||||||
<Setter TargetName="border" Property="Background" Value="#F0F6FB"/>
|
|
||||||
</Trigger>
|
|
||||||
</ControlTemplate.Triggers>
|
|
||||||
</ControlTemplate>
|
|
||||||
</Setter.Value>
|
|
||||||
</Setter>
|
|
||||||
</Style>
|
|
||||||
</ListBox.ItemContainerStyle>
|
|
||||||
<ListBox.ItemTemplate>
|
|
||||||
<DataTemplate>
|
|
||||||
<Border BorderBrush="#EFEFEF" BorderThickness="0,0,0,1">
|
|
||||||
<Grid Margin="10,15">
|
|
||||||
<Grid.ColumnDefinitions>
|
|
||||||
<ColumnDefinition />
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
</Grid.ColumnDefinitions>
|
|
||||||
<TextBlock Text="{Binding SamplingTime,StringFormat={}{0:yyyy-MM-dd HH:mm:ss}}" Foreground="#444" FontWeight="Normal" Grid.Column="0"/>
|
|
||||||
<TextBlock Text="{Binding FaultCodes}" FontSize="12" Grid.Column="1"/>
|
|
||||||
<TextBlock Text="{Binding C2Concentration}" FontSize="12" Grid.Column="2"/>
|
|
||||||
<TextBlock Text="{Binding C3Concentration}" FontSize="12" Grid.Column="3"/>
|
|
||||||
<TextBlock Text="{Binding C4Concentration}" FontSize="12" Grid.Column="4"/>
|
|
||||||
</Grid>
|
</Grid>
|
||||||
|
</StackPanel>
|
||||||
</Border>
|
</Border>
|
||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
</ListBox.ItemTemplate>
|
</ItemsControl.ItemTemplate>
|
||||||
</ListBox>
|
</ItemsControl>
|
||||||
</Grid>
|
|
||||||
|
|
||||||
</Grid>
|
|
||||||
|
|
||||||
</Grid>
|
|
||||||
|
|
||||||
<Grid Grid.Row="2">
|
|
||||||
<!--第一列-->
|
|
||||||
<Border CornerRadius="5" Background="#FAFCFF" Margin="10">
|
|
||||||
<Border.Effect>
|
|
||||||
<DropShadowEffect BlurRadius="10" ShadowDepth="0" Direction="0" Color="#555" Opacity="0.1"/>
|
|
||||||
</Border.Effect>
|
|
||||||
</Border>
|
|
||||||
<Grid Background="#FAFCFF" Margin="20">
|
|
||||||
<Grid.RowDefinitions>
|
|
||||||
<RowDefinition Height="45"/>
|
|
||||||
<RowDefinition/>
|
|
||||||
</Grid.RowDefinitions>
|
|
||||||
<!--列头-->
|
|
||||||
<Border Background="#EFEFEF" Height="1" VerticalAlignment="Bottom"/>
|
|
||||||
<TextBlock Text="MEMS质谱仪" FontSize="14" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="15,0" FontWeight="Normal" />
|
|
||||||
|
|
||||||
<Grid Grid.Row="1">
|
|
||||||
<Grid.RowDefinitions>
|
|
||||||
<RowDefinition/>
|
|
||||||
<RowDefinition/>
|
|
||||||
</Grid.RowDefinitions>
|
|
||||||
<Grid Grid.Row="0" TextBlock.FontSize="12" TextBlock.FontWeight="Bold" TextBlock.Foreground="#666" Margin="0,10">
|
|
||||||
<Grid.ColumnDefinitions>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
</Grid.ColumnDefinitions>
|
|
||||||
<TextBlock Text="采样时间" VerticalAlignment="Center" HorizontalAlignment="Center"/>
|
|
||||||
<TextBlock Text="故障代码" Grid.Column="1" VerticalAlignment="Center" HorizontalAlignment="Center"/>
|
|
||||||
<TextBlock Text="CH4浓度" Grid.Column="2" VerticalAlignment="Center" Margin="5,0"/>
|
|
||||||
<TextBlock Text="H2O浓度" Grid.Column="3" VerticalAlignment="Center" Margin="5,0"/>
|
|
||||||
<TextBlock Text="N2浓度" Grid.Column="4" VerticalAlignment="Center" Margin="5,0"/>
|
|
||||||
<TextBlock Text="O2浓度" Grid.Column="5" VerticalAlignment="Center" Margin="5,0"/>
|
|
||||||
<TextBlock Text="Ar浓度" Grid.Column="6" VerticalAlignment="Center" Margin="5,0"/>
|
|
||||||
<TextBlock Text="CO2浓度" Grid.Column="7" VerticalAlignment="Center" Margin="5,0"/>
|
|
||||||
</Grid>
|
|
||||||
<ListBox Grid.Row="1" Background="Transparent" BorderThickness="0" ItemsSource="{Binding MEMSMassList}">
|
|
||||||
<ListBox.ItemContainerStyle>
|
|
||||||
<Style TargetType="ListBoxItem">
|
|
||||||
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
|
|
||||||
<Setter Property="Template">
|
|
||||||
<Setter.Value>
|
|
||||||
<ControlTemplate TargetType="ListBoxItem">
|
|
||||||
<Border Background="Transparent" Name="border">
|
|
||||||
<ContentPresenter/>
|
|
||||||
</Border>
|
|
||||||
<ControlTemplate.Triggers>
|
|
||||||
<Trigger Property="IsMouseOver" Value="True">
|
|
||||||
<Setter TargetName="border" Property="Background" Value="#F0F6FB"/>
|
|
||||||
</Trigger>
|
|
||||||
</ControlTemplate.Triggers>
|
|
||||||
</ControlTemplate>
|
|
||||||
</Setter.Value>
|
|
||||||
</Setter>
|
|
||||||
</Style>
|
|
||||||
</ListBox.ItemContainerStyle>
|
|
||||||
<ListBox.ItemTemplate>
|
|
||||||
<DataTemplate>
|
|
||||||
<Border BorderBrush="#EFEFEF" BorderThickness="0,0,0,1">
|
|
||||||
<Grid Margin="10,15">
|
|
||||||
<Grid.ColumnDefinitions>
|
|
||||||
<ColumnDefinition />
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
<ColumnDefinition/>
|
|
||||||
</Grid.ColumnDefinitions>
|
|
||||||
<TextBlock Text="{Binding SamplingTime,StringFormat={}{0:yyyy-MM-dd HH:mm:ss}}" Foreground="#444" FontWeight="Normal" Grid.Column="0"/>
|
|
||||||
<TextBlock Text="{Binding FaultCodes}" FontSize="12" Grid.Column="1" Margin="40,0"/>
|
|
||||||
<TextBlock Text="{Binding CH4Concentration}" FontSize="12" Grid.Column="2"/>
|
|
||||||
<TextBlock Text="{Binding H2OConcentration}" FontSize="12" Grid.Column="3"/>
|
|
||||||
<TextBlock Text="{Binding N2Concentration}" FontSize="12" Grid.Column="4"/>
|
|
||||||
<TextBlock Text="{Binding O2Concentration}" FontSize="12" Grid.Column="5"/>
|
|
||||||
<TextBlock Text="{Binding ARConcentration}" FontSize="12" Grid.Column="6"/>
|
|
||||||
<TextBlock Text="{Binding CO2Concentration}" FontSize="12" Grid.Column="7"/>
|
|
||||||
</Grid>
|
|
||||||
</Border>
|
|
||||||
</DataTemplate>
|
|
||||||
</ListBox.ItemTemplate>
|
|
||||||
</ListBox>
|
|
||||||
</Grid>
|
|
||||||
|
|
||||||
</Grid>
|
|
||||||
|
|
||||||
</Grid>
|
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
</ScrollViewer>
|
</ScrollViewer>
|
||||||
</UserControl>
|
</UserControl>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user