添加阿里巴巴矢量图标库及数据中心布局
This commit is contained in:
parent
b2d8c59212
commit
ff47302010
BIN
InSituLaboratory.Assets/Fonts/iconfont1.ttf
Normal file
BIN
InSituLaboratory.Assets/Fonts/iconfont1.ttf
Normal file
Binary file not shown.
@ -9,6 +9,7 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<None Remove="Fonts\iconfont.ttf" />
|
<None Remove="Fonts\iconfont.ttf" />
|
||||||
|
<None Remove="Fonts\iconfont1.ttf" />
|
||||||
<None Remove="Fonts\方正楷体简体.ttf" />
|
<None Remove="Fonts\方正楷体简体.ttf" />
|
||||||
<None Remove="Images\20240201.jpg" />
|
<None Remove="Images\20240201.jpg" />
|
||||||
<None Remove="Images\6604cd8ecc29d.ico" />
|
<None Remove="Images\6604cd8ecc29d.ico" />
|
||||||
@ -28,6 +29,9 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<Resource Include="Fonts\iconfont1.ttf">
|
||||||
|
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||||
|
</Resource>
|
||||||
<Resource Include="Fonts\方正楷体简体.ttf">
|
<Resource Include="Fonts\方正楷体简体.ttf">
|
||||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||||
</Resource>
|
</Resource>
|
||||||
|
|||||||
51
InSituLaboratory.Base/StateBackConvert.cs
Normal file
51
InSituLaboratory.Base/StateBackConvert.cs
Normal file
@ -0,0 +1,51 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Globalization;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Data;
|
||||||
|
using System.Windows.Media;
|
||||||
|
|
||||||
|
namespace InSituLaboratory.Base
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 告警类别转换器
|
||||||
|
/// </summary>
|
||||||
|
public class StateBackConvert : IValueConverter
|
||||||
|
{
|
||||||
|
public static object ConvertObject;
|
||||||
|
|
||||||
|
object IValueConverter.Convert(object value, Type targetType, object parameter, CultureInfo culture)
|
||||||
|
{
|
||||||
|
Brush background = null;
|
||||||
|
if ((string)value == "正常")
|
||||||
|
{
|
||||||
|
//绿色
|
||||||
|
background = new SolidColorBrush(Color.FromRgb(0, 255, 0));
|
||||||
|
}
|
||||||
|
else if ((string)value == "一级报警")
|
||||||
|
{
|
||||||
|
//黄色
|
||||||
|
background = new SolidColorBrush(Color.FromRgb(255, 255, 0));
|
||||||
|
}
|
||||||
|
else if ((string)value == "二级报警")
|
||||||
|
{
|
||||||
|
//橙色
|
||||||
|
background = new SolidColorBrush(Color.FromRgb(255, 128, 0));
|
||||||
|
}
|
||||||
|
else if ((string)value == "故障")
|
||||||
|
{
|
||||||
|
//红色
|
||||||
|
background = new SolidColorBrush(Color.FromRgb(255, 0, 0));
|
||||||
|
}
|
||||||
|
|
||||||
|
return background;
|
||||||
|
}
|
||||||
|
|
||||||
|
object IValueConverter.ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
15
InSituLaboratory.IService/ISysStatusService.cs
Normal file
15
InSituLaboratory.IService/ISysStatusService.cs
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
using InSituLaboratory.Entities;
|
||||||
|
using InSituLaboratory.Entities.ExperimentalStationEntities;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace InSituLaboratory.IService
|
||||||
|
{
|
||||||
|
public interface ISysStatusService : IBaseService
|
||||||
|
{
|
||||||
|
IEnumerable<SysStatus> GetSysStauts();
|
||||||
|
}
|
||||||
|
}
|
||||||
27
InSituLaboratory.Service/SysStatusService.cs
Normal file
27
InSituLaboratory.Service/SysStatusService.cs
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
using InSituLaboratory.Entities;
|
||||||
|
using InSituLaboratory.Entities.ExperimentalStationEntities;
|
||||||
|
using InSituLaboratory.IService;
|
||||||
|
using Microsoft.EntityFrameworkCore;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace InSituLaboratory.Service
|
||||||
|
{
|
||||||
|
public class SysStatusService : BaseService, ISysStatusService
|
||||||
|
{
|
||||||
|
public SysStatusService(DbContext context) : base(context) { }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public IEnumerable<SysStatus> GetSysStauts()
|
||||||
|
{
|
||||||
|
return this.Set<SysStatus>().OrderByDescending(n => n.CreateTime);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -18,6 +18,7 @@
|
|||||||
|
|
||||||
<ResourceDictionary>
|
<ResourceDictionary>
|
||||||
<FontFamily x:Key="Icons">/InSituLaboratory.Assets;component/Fonts/iconfont.ttf#zx_icons</FontFamily>
|
<FontFamily x:Key="Icons">/InSituLaboratory.Assets;component/Fonts/iconfont.ttf#zx_icons</FontFamily>
|
||||||
|
<FontFamily x:Key="IconsExt">/InSituLaboratory.Assets;component/Fonts/iconfont1.ttf#iconfont</FontFamily>
|
||||||
<FontFamily x:Key="DigitalDisplay">/InSituLaboratory.Assets;component/Fonts/#方正楷体简体</FontFamily>
|
<FontFamily x:Key="DigitalDisplay">/InSituLaboratory.Assets;component/Fonts/#方正楷体简体</FontFamily>
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
</ResourceDictionary.MergedDictionaries>
|
</ResourceDictionary.MergedDictionaries>
|
||||||
|
|||||||
@ -53,6 +53,7 @@ namespace InSituLaboratory
|
|||||||
containerRegistry.Register<ICavityBatteryLevelService, CavityBatteryLevelService>();
|
containerRegistry.Register<ICavityBatteryLevelService, CavityBatteryLevelService>();
|
||||||
containerRegistry.Register<ISysSequentialService, SysSequentialService>();
|
containerRegistry.Register<ISysSequentialService, SysSequentialService>();
|
||||||
containerRegistry.Register<IDeviceSvice, DeviceService>();
|
containerRegistry.Register<IDeviceSvice, DeviceService>();
|
||||||
|
containerRegistry.Register<ISysStatusService, SysStatusService>();
|
||||||
|
|
||||||
|
|
||||||
containerRegistry.RegisterForNavigation<Views.Pages.DashboardView>();
|
containerRegistry.RegisterForNavigation<Views.Pages.DashboardView>();
|
||||||
|
|||||||
@ -15,6 +15,7 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\InSituLaboratory.Assets\InSituLaboratory.Assets.csproj" />
|
<ProjectReference Include="..\InSituLaboratory.Assets\InSituLaboratory.Assets.csproj" />
|
||||||
|
<ProjectReference Include="..\InSituLaboratory.Base\InSituLaboratory.Base.csproj" />
|
||||||
<ProjectReference Include="..\InSituLaboratory.Controls\InSituLaboratory.Controls.csproj" />
|
<ProjectReference Include="..\InSituLaboratory.Controls\InSituLaboratory.Controls.csproj" />
|
||||||
<ProjectReference Include="..\InSituLaboratory.IService\InSituLaboratory.IService.csproj" />
|
<ProjectReference Include="..\InSituLaboratory.IService\InSituLaboratory.IService.csproj" />
|
||||||
<ProjectReference Include="..\InSituLaboratory.Models\InSituLaboratory.Models.csproj" />
|
<ProjectReference Include="..\InSituLaboratory.Models\InSituLaboratory.Models.csproj" />
|
||||||
|
|||||||
@ -9,20 +9,80 @@ using System.Text;
|
|||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using InSituLaboratory.Models;
|
using InSituLaboratory.Models;
|
||||||
using InSituLaboratory.Entities.ExperimentalStationEntities;
|
using InSituLaboratory.Entities.ExperimentalStationEntities;
|
||||||
|
using Prism.Regions;
|
||||||
|
using InSituLaboratory.IService;
|
||||||
|
|
||||||
namespace InSituLaboratory.ViewModels.Pages
|
namespace InSituLaboratory.ViewModels.Pages
|
||||||
{
|
{
|
||||||
public class DashboardViewModel : ViewModelBase
|
public class DashboardViewModel : ViewModelBase
|
||||||
{
|
{
|
||||||
public ObservableCollection<SysStatus> SysStatusList { get; set; } = new ObservableCollection<SysStatus>();
|
#region 实体类
|
||||||
|
/// <summary>
|
||||||
|
/// 组包时间
|
||||||
|
/// </summary>
|
||||||
|
private DateTime? _packagingTime;
|
||||||
|
public DateTime? PackagingTime
|
||||||
|
{
|
||||||
|
get { return _packagingTime; }
|
||||||
|
set { SetProperty(ref _packagingTime, value); }
|
||||||
|
}
|
||||||
|
|
||||||
public DashboardViewModel() : base(null)
|
/// <summary>
|
||||||
|
/// 采样时间
|
||||||
|
/// </summary>
|
||||||
|
private DateTime? _samplingTime;
|
||||||
|
public DateTime? SamplingTime
|
||||||
|
{
|
||||||
|
get { return _samplingTime; }
|
||||||
|
set { SetProperty(ref _samplingTime, value); }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 48V 电压
|
||||||
|
/// </summary>
|
||||||
|
private float? _voltage48;
|
||||||
|
public float? Voltage48
|
||||||
|
{
|
||||||
|
get { return _voltage48; }
|
||||||
|
set { SetProperty(ref _voltage48, value); }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 48V 电流
|
||||||
|
/// </summary>
|
||||||
|
private float? _current48;
|
||||||
|
public float? Current48
|
||||||
|
{
|
||||||
|
get { return _current48; }
|
||||||
|
set { SetProperty(ref _current48, value); }
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
ISysStatusService _sysStatusService;
|
||||||
|
public DashboardViewModel(IRegionManager regionManager, ISysStatusService isysStatusService) : base(regionManager)
|
||||||
{
|
{
|
||||||
PageTitle = "数据中心";
|
PageTitle = "数据中心";
|
||||||
IsCanClose = false;
|
IsCanClose = false;
|
||||||
|
_sysStatusService = isysStatusService;
|
||||||
|
|
||||||
|
this.Refresh();
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void Refresh()
|
||||||
|
{
|
||||||
|
var sysStatuslist = _sysStatusService.GetSysStauts().ToList();
|
||||||
|
if (sysStatuslist.Count() != 0)
|
||||||
|
{
|
||||||
|
var data = _sysStatusService.GetSysStauts().First();
|
||||||
|
|
||||||
|
PackagingTime = data.PackagingTime;
|
||||||
|
SamplingTime = data.SamplingTime;
|
||||||
|
Voltage48 = data.Voltage48;
|
||||||
|
Current48 = data.Current48;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -4,50 +4,217 @@
|
|||||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
xmlns:local="clr-namespace:InSituLaboratory.Views.Pages"
|
xmlns:local="clr-namespace:InSituLaboratory.Views.Pages"
|
||||||
|
xmlns:converters="clr-namespace:InSituLaboratory.Base;assembly=InSituLaboratory.Base"
|
||||||
mc:Ignorable="d"
|
mc:Ignorable="d"
|
||||||
FontFamily="{StaticResource DigitalDisplay}"
|
FontFamily="{StaticResource DigitalDisplay}"
|
||||||
d:DesignHeight="450" d:DesignWidth="800">
|
d:DesignHeight="450" d:DesignWidth="800">
|
||||||
|
<UserControl.Resources>
|
||||||
|
<converters:StateBackConvert x:Key="StateBackConvert" />
|
||||||
|
<Style TargetType="GroupBox">
|
||||||
|
<Setter Property="Margin" Value="10,5" />
|
||||||
|
<Setter Property="Template">
|
||||||
|
<Setter.Value>
|
||||||
|
<ControlTemplate TargetType="GroupBox">
|
||||||
|
<Grid>
|
||||||
|
<!-- 左上角 -->
|
||||||
|
<Polyline HorizontalAlignment="Left" VerticalAlignment="Top" Points="0 30, 0 10, 10 0, 30 0" Stroke="#9918AABD" StrokeThickness="1" />
|
||||||
|
<!-- 左上角点 -->
|
||||||
|
<Ellipse Width="4" Height="4" Margin="24,-2,0,0" HorizontalAlignment="Left" VerticalAlignment="Top" Fill="#9918AABD" />
|
||||||
|
<Ellipse Width="4" Height="4" Margin="-2,24,0,0" HorizontalAlignment="Left" VerticalAlignment="Top" Fill="#9918AABD" />
|
||||||
|
<!-- 右上角 -->
|
||||||
|
<Path HorizontalAlignment="Right" VerticalAlignment="Top" Data="M0 0, 3 3, 30 3, 33 0, 68 0, 73 7,78 7, 78 10M8 0, 25 0" Stroke="#5518AABD" />
|
||||||
|
<!-- 左下角 -->
|
||||||
|
<Polyline HorizontalAlignment="Left" VerticalAlignment="Bottom" Points="0,0 0,15 10,15" Stroke="#5518AABD" />
|
||||||
|
<!-- 右下角 -->
|
||||||
|
<Polyline HorizontalAlignment="Right" VerticalAlignment="Bottom" Points="10,0 0,10" Stroke="#5518AABD" />
|
||||||
|
<!-- 右下角图标 -->
|
||||||
|
<Polygon HorizontalAlignment="Right" VerticalAlignment="Bottom" Fill="#9918AABD" Points="0,7 7 7 7 0" />
|
||||||
|
|
||||||
|
<Border Margin="30,-0.5,78,0" VerticalAlignment="Top" BorderBrush="#5518AABD" BorderThickness="0,1,0,0" />
|
||||||
|
<Border Margin="0,10" HorizontalAlignment="Right" BorderBrush="#5518AABD" BorderThickness="0,0,1,0" />
|
||||||
|
<Border Margin="10,0" VerticalAlignment="Bottom" BorderBrush="#5518AABD" BorderThickness="0,1,0,0" />
|
||||||
|
<Border Margin="-0.5,15" HorizontalAlignment="Left" BorderBrush="#5518AABD" BorderThickness="0,0,1,0" />
|
||||||
|
|
||||||
|
<!-- 箭头 -->
|
||||||
|
<Path Margin="10,13" HorizontalAlignment="Left" VerticalAlignment="Top" Data="M0 0,3 0,5 4,3 8,0 8,3 4" Fill="#9918AABD" />
|
||||||
|
<Path Margin="16,13" HorizontalAlignment="Left" VerticalAlignment="Top" Data="M0 0,3 0,5 4,3 8,0 8,3 4" Fill="#5518AABD" />
|
||||||
|
<!-- 字体 -->
|
||||||
|
<TextBlock Margin="25,8" HorizontalAlignment="Left" VerticalAlignment="Top" Foreground="#18AABD" Text="{TemplateBinding Header}" FontSize="18"/>
|
||||||
|
<!-- 占位对象 -->
|
||||||
|
<ContentPresenter />
|
||||||
|
</Grid>
|
||||||
|
</ControlTemplate>
|
||||||
|
</Setter.Value>
|
||||||
|
</Setter>
|
||||||
|
</Style>
|
||||||
|
|
||||||
|
</UserControl.Resources>
|
||||||
<ScrollViewer Margin="0,5,0,10">
|
<ScrollViewer Margin="0,5,0,10">
|
||||||
<Grid>
|
<Grid>
|
||||||
<Grid.RowDefinitions>
|
<Grid.RowDefinitions>
|
||||||
<RowDefinition Height="auto"/>
|
<RowDefinition Height="300" />
|
||||||
<RowDefinition Height="auto"/>
|
<RowDefinition />
|
||||||
<RowDefinition Height="auto"/>
|
<RowDefinition />
|
||||||
<RowDefinition Height="auto"/>
|
<RowDefinition />
|
||||||
<RowDefinition Height="auto"/>
|
<RowDefinition />
|
||||||
</Grid.RowDefinitions>
|
</Grid.RowDefinitions>
|
||||||
|
<!--第一行-->
|
||||||
|
<UniformGrid Columns="5" Rows="3" Grid.Row="0">
|
||||||
|
<!--组包时间-->
|
||||||
|
<Border CornerRadius="5" Background="#FAFCFF" Margin="10">
|
||||||
|
<Border.Effect>
|
||||||
|
<DropShadowEffect BlurRadius="10" ShadowDepth="0" Color="#555" Opacity="0.1"/>
|
||||||
|
</Border.Effect>
|
||||||
|
<StackPanel Margin="30,10" Orientation="Vertical" >
|
||||||
|
<TextBlock Foreground="#AAA" Margin="0,10,0,5" FontSize="12">
|
||||||
|
<Run Text="" FontFamily="{StaticResource IconsExt}" Foreground="#088DF6" FontSize="18"/>
|
||||||
|
<Run Text="组包时间" FontSize="18"/>
|
||||||
|
</TextBlock>
|
||||||
|
|
||||||
<!--第二行-->
|
<TextBlock Text="{Binding PackagingTime ,Mode=TwoWay,StringFormat={}{0:yyyy-MM-dd HH:mm:ss}}" FontSize="15" FontWeight="Normal" Foreground="#555"/>
|
||||||
<ItemsControl ItemsSource="{Binding BoardList}">
|
|
||||||
<ItemsControl.ItemsPanel>
|
|
||||||
<ItemsPanelTemplate>
|
|
||||||
<UniformGrid Rows="1"/>
|
|
||||||
</ItemsPanelTemplate>
|
|
||||||
</ItemsControl.ItemsPanel>
|
|
||||||
<ItemsControl.ItemTemplate>
|
|
||||||
<DataTemplate>
|
|
||||||
<Border CornerRadius="5" Background="#FAFCFF" Margin="10">
|
|
||||||
<Border.Effect>
|
|
||||||
<DropShadowEffect BlurRadius="10" ShadowDepth="0"
|
|
||||||
Color="#555" Opacity="0.1"/>
|
|
||||||
</Border.Effect>
|
|
||||||
<StackPanel Margin="30,10">
|
|
||||||
<TextBlock Foreground="#AAA" Margin="0,10,0,5" FontSize="12">
|
|
||||||
<Run Text="{Binding Icon}" FontFamily="{StaticResource Icons}" Foreground="{Binding Color}" FontSize="15"/>
|
|
||||||
<Run Text="{Binding Header}"/>
|
|
||||||
</TextBlock>
|
|
||||||
|
|
||||||
<TextBlock Text="{Binding Value,StringFormat={}{0:N0}}" FontSize="22" FontWeight="Normal" Foreground="#555"/>
|
<Grid TextBlock.FontSize="11">
|
||||||
|
<TextBlock HorizontalAlignment="Left" Foreground="Green">
|
||||||
|
</TextBlock>
|
||||||
|
</Grid>
|
||||||
|
</StackPanel>
|
||||||
|
</Border>
|
||||||
|
|
||||||
<Grid Margin="0,5,0,10" TextBlock.FontSize="11">
|
<!--采样时间-->
|
||||||
<TextBlock HorizontalAlignment="Left" Foreground="Green">
|
<Border CornerRadius="5" Background="#FAFCFF" Margin="10">
|
||||||
</TextBlock>
|
<Border.Effect>
|
||||||
|
<DropShadowEffect BlurRadius="10" ShadowDepth="0" Color="#555" Opacity="0.1"/>
|
||||||
|
</Border.Effect>
|
||||||
|
<StackPanel Margin="30,10" Orientation="Vertical" >
|
||||||
|
<TextBlock Foreground="#AAA" Margin="0,10,0,5" FontSize="12">
|
||||||
|
<Run Text="" FontFamily="{StaticResource IconsExt}" Foreground="#088DF6" FontSize="18"/>
|
||||||
|
<Run Text="采样时间" FontSize="18"/>
|
||||||
|
</TextBlock>
|
||||||
|
|
||||||
|
<TextBlock Text="{Binding SamplingTime ,Mode=TwoWay,StringFormat={}{0:yyyy-MM-dd HH:mm:ss}}" FontSize="15" FontWeight="Normal" Foreground="#555"/>
|
||||||
|
|
||||||
|
<Grid TextBlock.FontSize="11">
|
||||||
|
<TextBlock HorizontalAlignment="Left" Foreground="Green">
|
||||||
|
</TextBlock>
|
||||||
|
</Grid>
|
||||||
|
</StackPanel>
|
||||||
|
</Border>
|
||||||
|
|
||||||
|
<!--48V电压-->
|
||||||
|
<Border CornerRadius="5" Background="#FAFCFF" Margin="10">
|
||||||
|
<Border.Effect>
|
||||||
|
<DropShadowEffect BlurRadius="10" ShadowDepth="0" Color="#555" Opacity="0.1"/>
|
||||||
|
</Border.Effect>
|
||||||
|
<StackPanel Margin="30,10" Orientation="Vertical" >
|
||||||
|
<TextBlock Foreground="#AAA" Margin="0,10,0,5" FontSize="12">
|
||||||
|
<Run Text="" FontFamily="{StaticResource IconsExt}" Foreground="#088DF6" FontSize="18"/>
|
||||||
|
<Run Text="48V电压" FontSize="18"/>
|
||||||
|
</TextBlock>
|
||||||
|
|
||||||
|
<TextBlock Text="{Binding Voltage48 ,Mode=TwoWay,StringFormat={}{0}V}" FontSize="15" FontWeight="Normal" Foreground="#555"/>
|
||||||
|
|
||||||
|
<Grid TextBlock.FontSize="11">
|
||||||
|
<TextBlock HorizontalAlignment="Left" Foreground="Green">
|
||||||
|
</TextBlock>
|
||||||
|
</Grid>
|
||||||
|
</StackPanel>
|
||||||
|
</Border>
|
||||||
|
|
||||||
|
<!--48V电流-->
|
||||||
|
<Border CornerRadius="5" Background="#FAFCFF" Margin="10">
|
||||||
|
<Border.Effect>
|
||||||
|
<DropShadowEffect BlurRadius="10" ShadowDepth="0" Color="#555" Opacity="0.1"/>
|
||||||
|
</Border.Effect>
|
||||||
|
<StackPanel Margin="30,10" Orientation="Vertical" >
|
||||||
|
<TextBlock Foreground="#AAA" Margin="0,10,0,5" FontSize="12">
|
||||||
|
<Run Text="" FontFamily="{StaticResource IconsExt}" Foreground="#088DF6" FontSize="18"/>
|
||||||
|
<Run Text="48V电流" FontSize="18"/>
|
||||||
|
</TextBlock>
|
||||||
|
|
||||||
|
<TextBlock Text="{Binding Current48 ,Mode=TwoWay,StringFormat={}{0}A}" FontSize="15" FontWeight="Normal" Foreground="#555"/>
|
||||||
|
|
||||||
|
<Grid TextBlock.FontSize="11">
|
||||||
|
<TextBlock HorizontalAlignment="Left" Foreground="Green">
|
||||||
|
</TextBlock>
|
||||||
|
</Grid>
|
||||||
|
</StackPanel>
|
||||||
|
</Border>
|
||||||
|
</UniformGrid>
|
||||||
|
|
||||||
|
<!-- 主腔体状态 -->
|
||||||
|
<Grid Margin="0,100,0,0" Grid.RowSpan="2">
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="30" />
|
||||||
|
<RowDefinition />
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<StackPanel Grid.Row="0" Margin="0,0,10,0" HorizontalAlignment="Right" VerticalAlignment="Center" Orientation="Horizontal">
|
||||||
|
<TextBlock Text="正常" Margin="10,5"/>
|
||||||
|
<Border Width="20" Height="20" Background="Green" CornerRadius="10" />
|
||||||
|
<TextBlock Text="一级告警" Margin="10,5"/>
|
||||||
|
<Border Width="20" Height="20" Background="Yellow" CornerRadius="10" />
|
||||||
|
<TextBlock Text="二级告警" Margin="10,5"/>
|
||||||
|
<Border Width="20" Height="20" Background="Orange" CornerRadius="10" />
|
||||||
|
<TextBlock Text="故障" Margin="10,5"/>
|
||||||
|
<Border Width="20" Height="20" Background="red" CornerRadius="10" />
|
||||||
|
</StackPanel>
|
||||||
|
<Grid Grid.Row="1">
|
||||||
|
<GroupBox Header="主腔体状态">
|
||||||
|
<Grid>
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition/>
|
||||||
|
<ColumnDefinition/>
|
||||||
|
<ColumnDefinition/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<Grid Grid.Column="0">
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="30"/>
|
||||||
|
<RowDefinition />
|
||||||
|
<RowDefinition/>
|
||||||
|
<RowDefinition/>
|
||||||
|
<RowDefinition/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<Grid Grid.Row="1">
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition />
|
||||||
|
<ColumnDefinition />
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<TextBlock Grid.Column="0" Text="基站48V漏电流状态" FontSize="16" Grid.ColumnSpan="2" Margin="0,0,98,0" />
|
||||||
|
<Border Grid.Column="1" Width="20" Height="20" Background="Green" CornerRadius="10" />
|
||||||
</Grid>
|
</Grid>
|
||||||
</StackPanel>
|
<Grid Grid.Row="2">
|
||||||
</Border>
|
<Grid.ColumnDefinitions>
|
||||||
</DataTemplate>
|
<ColumnDefinition />
|
||||||
</ItemsControl.ItemTemplate>
|
<ColumnDefinition />
|
||||||
</ItemsControl>
|
</Grid.ColumnDefinitions>
|
||||||
|
<TextBlock Grid.Column="0" Text="电池48V漏电流状态" Grid.ColumnSpan="2" Margin="17,2,100,13" FontSize="16"/>
|
||||||
|
<Border Grid.Column="1" Width="20" Height="20" Background="Green" CornerRadius="10" Margin="39,1,71,22" />
|
||||||
|
</Grid>
|
||||||
|
<Grid Grid.Row="3">
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition />
|
||||||
|
<ColumnDefinition />
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<TextBlock Grid.Column="0" Text="ICL漏电流状态" Grid.ColumnSpan="2" Margin="26,15,104,0" FontSize="16"/>
|
||||||
|
<Border Grid.Column="1" Width="20" Height="20" Background="Green" CornerRadius="10" Margin="0,15,104,0" />
|
||||||
|
</Grid>
|
||||||
|
<Grid Grid.Row="4">
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition />
|
||||||
|
<ColumnDefinition />
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<TextBlock Grid.Column="0" Text="工控机漏电流状态" Grid.ColumnSpan="2" Margin="26,15,104,0" FontSize="16"/>
|
||||||
|
<Border Grid.Column="1" Width="20" Height="20" Background="Green" CornerRadius="10" Margin="0,15,104,0" />
|
||||||
|
</Grid>
|
||||||
|
</Grid>
|
||||||
|
</Grid>
|
||||||
|
</GroupBox>
|
||||||
|
</Grid>
|
||||||
|
</Grid>
|
||||||
|
|
||||||
|
<Grid Grid.Row="2"/>
|
||||||
|
<Grid Grid.Row="3"/>
|
||||||
|
<Grid Grid.Row="4"/>
|
||||||
|
<Grid Grid.Row="5"/>
|
||||||
</Grid>
|
</Grid>
|
||||||
</ScrollViewer>
|
</ScrollViewer>
|
||||||
</UserControl>
|
</UserControl>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user