diff --git a/InSituLaboratory.Entities/ExperimentalStationEntities/CurrentFaultyEquipment.cs b/InSituLaboratory.Entities/ExperimentalStationEntities/CurrentFaultyEquipment.cs
new file mode 100644
index 0000000..b42bd29
--- /dev/null
+++ b/InSituLaboratory.Entities/ExperimentalStationEntities/CurrentFaultyEquipment.cs
@@ -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
+{
+ ///
+ /// 当前故障设备 0-正常 1-故障
+ ///
+ public class CurrentFaultyEquipment
+ {
+ ///
+ /// ID
+ ///
+ [Key]
+ public int Id { get; set; }
+
+ ///
+ /// 采样时间
+ ///
+ public DateTime? SamplingTime { get; set; }
+
+ ///
+ /// 创建时间
+ ///
+ public DateTime? CreateTime { get; set; }
+
+ ///
+ /// MEMS色谱仪
+ ///
+ public string? Chromatograph_MEMS { get; set; }
+
+ ///
+ /// MEMS质谱仪
+ ///
+ public string? MassSpectrometer_MEMS { get; set; }
+
+ ///
+ /// 色质联用仪
+ ///
+ public string? ColorMassSpectrometer { get; set; }
+
+ ///
+ /// 甲烷同位素分析仪
+ ///
+ public string? CH4Analyzer { get; set; }
+
+ ///
+ /// 二氧化碳同位素分析仪
+ ///
+ public string? CO2Analyzer { get; set; }
+
+ ///
+ /// 颗粒物分析仪
+ ///
+ public string? ParticleAnalyzer { get; set; }
+
+ ///
+ /// 测序仪
+ ///
+ public string? Sequencer { get; set; }
+ }
+}
diff --git a/InSituLaboratory.Entities/ExperimentalStationEntities/CurrentWorkEquipment.cs b/InSituLaboratory.Entities/ExperimentalStationEntities/CurrentWorkEquipment.cs
new file mode 100644
index 0000000..27036dd
--- /dev/null
+++ b/InSituLaboratory.Entities/ExperimentalStationEntities/CurrentWorkEquipment.cs
@@ -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
+{
+ ///
+ /// 当前工作设备 0-待机 1-工作
+ ///
+ public class CurrentWorkEquipment
+ {
+ ///
+ /// ID
+ ///
+ [Key]
+ public int Id { get; set; }
+
+ ///
+ /// 采样时间
+ ///
+ public DateTime? SamplingTime { get; set; }
+
+ ///
+ /// 创建时间
+ ///
+ public DateTime? CreateTime { get; set; }
+
+ ///
+ /// MEMS色谱仪
+ ///
+ public string? Chromatograph_MEMS { get; set; }
+
+ ///
+ /// MEMS质谱仪
+ ///
+ public string? MassSpectrometer_MEMS { get; set; }
+
+ ///
+ /// 色质联用仪
+ ///
+ public string? ColorMassSpectrometer { get; set; }
+
+ ///
+ /// 甲烷同位素分析仪
+ ///
+ public string? CH4Analyzer { get; set; }
+
+ ///
+ /// 二氧化碳同位素分析仪
+ ///
+ public string? CO2Analyzer { get; set; }
+
+ ///
+ /// 颗粒物分析仪
+ ///
+ public string? ParticleAnalyzer { get; set; }
+
+ ///
+ /// 测序仪
+ ///
+ public string? Sequencer { get; set; }
+ }
+}
diff --git a/InSituLaboratory.Entities/ExperimentalStationEntities/SysStatus.cs b/InSituLaboratory.Entities/ExperimentalStationEntities/SysStatus.cs
new file mode 100644
index 0000000..ce57318
--- /dev/null
+++ b/InSituLaboratory.Entities/ExperimentalStationEntities/SysStatus.cs
@@ -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
+{
+ ///
+ /// 系统状态
+ ///
+ public class SysStatus
+ {
+ ///
+ /// ID
+ ///
+ [Key]
+ public int Id { get; set; }
+
+ ///
+ /// 组包时间
+ ///
+ public DateTime? PackagingTime { get; set; }
+
+ ///
+ /// 采样时间
+ ///
+ public DateTime? SamplingTime { get; set; }
+
+ ///
+ /// 创建时间
+ ///
+ public DateTime? CreateTime { get; set; }
+
+ ///
+ /// 48V 电压
+ ///
+ public float? Voltage48 { get; set; }
+
+ ///
+ /// 48V 电流
+ ///
+ public float? Current48 { get; set; }
+
+
+ ///
+ /// 基站48V漏电流状态 第0位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? BaseStation48VLeakageCS { get; set; }
+
+ ///
+ /// 电池48V漏电流状态 第2位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? Batterz48VLeakageCS { get; set; }
+
+
+ ///
+ /// ICL漏电流状态 第4位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? ICLLeakageCS { get; set; }
+
+ ///
+ /// 工控机漏电流状态 第6位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? IComputerLeakageCS { get; set; }
+
+ ///
+ /// 温度1状态 第8位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? TemperatureStaus1 { get; set; }
+
+ ///
+ /// 温度2状态 第10位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? TemperatureStaus2 { get; set; }
+
+ ///
+ /// 湿度1状态 第12位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? HumidityStaus1 { get; set; }
+
+ ///
+ /// 湿度2状态 第14位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? HumidityStaus2 { get; set; }
+
+ ///
+ /// 漏水1状态 第16位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? LeakageStaus1 { get; set; }
+
+ ///
+ /// 漏水2状态 第18位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? LeakageStaus2 { get; set; }
+
+ ///
+ /// 内部压力1状态 第20位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? InternalPressure1 { get; set; }
+
+ ///
+ /// 内部压力2状态 第22位 (0表示该状态正常,1表示1级报警,2表示2级报警,3表示故障)
+ ///
+ public string? InternalPressure2 { get; set; }
+
+ ///
+ /// 时序组号
+ ///
+ public string? TimeSeriesGroupNumber { get; set; }
+
+ ///
+ /// 时序状态 0表示保持,1表示成功,2表示错误
+ ///
+ public string? GroupNumberStatus { get; set; }
+
+ }
+}
diff --git a/InSituLaboratory.Models/BoardModel.cs b/InSituLaboratory.Models/BoardModel.cs
new file mode 100644
index 0000000..5c7ac70
--- /dev/null
+++ b/InSituLaboratory.Models/BoardModel.cs
@@ -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; }
+ }
+}
diff --git a/InSituLaboratory.ORM/NoimptyDbContext.cs b/InSituLaboratory.ORM/NoimptyDbContext.cs
index f204856..3211586 100644
--- a/InSituLaboratory.ORM/NoimptyDbContext.cs
+++ b/InSituLaboratory.ORM/NoimptyDbContext.cs
@@ -1,5 +1,6 @@
using InSituLaboratory.Entities;
+using InSituLaboratory.Entities.ExperimentalStationEntities;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using System.Globalization;
@@ -69,5 +70,8 @@ namespace InSituLaboratory.ORM
public virtual DbSet SysSequentialDetails { get; set; }
public virtual DbSet SysDevice { get; set; }
public virtual DbSet SysSequentialTotal { get; set; }
+ public virtual DbSet CurrentFaultyEquipment { get; set; }
+ public virtual DbSet CurrentWorkEquipment { get; set; }
+ public virtual DbSet SysStatus { get; set; }
}
}
diff --git a/InSituLaboratory/ViewModels/Pages/DashboardViewModel.cs b/InSituLaboratory/ViewModels/Pages/DashboardViewModel.cs
index a26d97d..517e19e 100644
--- a/InSituLaboratory/ViewModels/Pages/DashboardViewModel.cs
+++ b/InSituLaboratory/ViewModels/Pages/DashboardViewModel.cs
@@ -8,28 +8,20 @@ using System.Linq;
using System.Text;
using System.Threading.Tasks;
using InSituLaboratory.Models;
+using InSituLaboratory.Entities.ExperimentalStationEntities;
namespace InSituLaboratory.ViewModels.Pages
{
public class DashboardViewModel : ViewModelBase
{
- public ObservableCollection MEMSList { get; set; } = new ObservableCollection();
- public ObservableCollection MEMSMassList { get; set; } = new ObservableCollection();
+ public ObservableCollection SysStatusList { get; set; } = new ObservableCollection();
+
public DashboardViewModel() : base(null)
{
PageTitle = "数据中心";
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"});
+
}
}
diff --git a/InSituLaboratory/Views/Pages/DashboardView.xaml b/InSituLaboratory/Views/Pages/DashboardView.xaml
index 51d0ec8..8daa235 100644
--- a/InSituLaboratory/Views/Pages/DashboardView.xaml
+++ b/InSituLaboratory/Views/Pages/DashboardView.xaml
@@ -7,191 +7,47 @@
mc:Ignorable="d"
FontFamily="{StaticResource DigitalDisplay}"
d:DesignHeight="450" d:DesignWidth="800">
-
-
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+