WinMain.xaml
8.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
<win:BaseWindow
xmlns:win="clr-namespace:HHECS.View.Win"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:model ="clr-namespace:HHECS.Model;assembly=HHECS.Model"
x:Class="HHECS.View.WinMain"
mc:Ignorable="d"
Title="华恒ECS" Height="450" Width="800" Loaded="Window_Loaded" Closed="Window_Closed" Background="#FF293955">
<DockPanel>
<Menu x:Name="MenuMain" DockPanel.Dock="Top" MenuItem.Click="MenuMain_Checked" Background="#FFD6DBE9">
<Menu.ItemTemplate>
<HierarchicalDataTemplate DataType="{x:Type model:MenuOperation}" ItemsSource="{Binding Children}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding MenuName}"/>
</StackPanel>
</HierarchicalDataTemplate>
</Menu.ItemTemplate>
</Menu>
<ToolBar DockPanel.Dock="Top" Background="#FFCFD6E5" FontSize="12">
<Button x:Name="Btn_LED" Click="Btn_LED_Click" Content="测试LED" Visibility="Collapsed"/>
<Button x:Name="Btn_ReConnectWMS" Click="Btn_ReConnectWMS_Click" Content="重连WMS"/>
<Button x:Name="Btn_BeginExcute" Click="Btn_BeginExcute_Click" Content="开始处理"/>
<Button x:Name="Btn_EndExcute" Click="Btn_EndExcute_Click" IsEnabled="False" Content="停止处理"/>
</ToolBar>
<StatusBar DockPanel.Dock="Bottom" Background="#FF007ACC">
<Label x:Name="Lab1" Foreground="White"/>
</StatusBar>
<Grid>
<TabControl >
<TabItem Header="主页">
<Grid x:Name="GridMain" >
<Grid.RowDefinitions>
<RowDefinition Height="35"/>
<RowDefinition Height="25*"/>
<RowDefinition Height="75*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="30*"/>
<ColumnDefinition Width="70*"/>
</Grid.ColumnDefinitions>
<Viewbox Grid.Column="0" Grid.ColumnSpan="2">
<TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="24" FontWeight="Bold"><Run Text="通 达"/><Run Text=" WCS 监 控"/></TextBlock>
</Viewbox>
<Grid Grid.Row="1" Grid.ColumnSpan="2" Grid.Column="0">
<ScrollViewer Grid.Column="1" x:Name="StockerView" ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto"/>
</Grid>
<GridSplitter BorderThickness="5"/>
<Grid Grid.Row="2" Grid.Column="0" Grid.ColumnSpan="3">
<TabControl >
<TabItem Header="日志及面板">
<StackPanel x:Name="EquipmentPanel" HorizontalAlignment="Left" VerticalAlignment="Top" Orientation="Horizontal" >
</StackPanel>
</TabItem>
<TabItem Header="站台监控">
<Border Grid.Row="2" BorderBrush="SteelBlue" BorderThickness="0,0,1,0">
<ScrollViewer ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto">
<StackPanel x:Name="SPMain" HorizontalAlignment="Left" VerticalAlignment="Top" Orientation="Horizontal" >
<DataGrid x:Name="DGStation" IsReadOnly="True" Height="{Binding Height, ElementName=SPMain}">
<DataGrid.Columns>
<DataGridTextColumn Header="站台名" Binding="{Binding Name}"/>
<DataGridTextColumn Header="P-开关量" Binding="{Binding WCSCanOut}"/>
<DataGridTextColumn Header="P-报文" Binding="{Binding RequestMessage}"/>
<DataGridTextColumn Header="P-装载" Binding="{Binding RequestLoadStatus}"/>
<DataGridTextColumn Header="P-读码器" Binding="{Binding RequestNumber}"/>
<DataGridTextColumn Header="P-条码" Binding="{Binding RequestBarcode}"/>
<DataGridTextColumn Header="P-重量" Binding="{Binding RequestWeight}"/>
<!--<DataGridTextColumn Header="请求-长度" Binding="{Binding RequestLength}"/>
<DataGridTextColumn Header="请求-宽度" Binding="{Binding RequestWidth}"/>-->
<DataGridTextColumn Header="P-高度" Binding="{Binding RequestHeight}"/>
<DataGridTextColumn Header="P-RetCode" Binding="{Binding RequestRetCode}"/>
<DataGridTextColumn Header="W-报文" Binding="{Binding WCSReplyMessage}"/>
<DataGridTextColumn Header="W-装载" Binding="{Binding WCSReplyLoadStatus}"/>
<DataGridTextColumn Header="W-读码器" Binding="{Binding WCSReplyNumber}"/>
<DataGridTextColumn Header="W-条码" Binding="{Binding WCSReplyBarcode}"/>
<DataGridTextColumn Header="W-重量" Binding="{Binding WCSReplyWeight}"/>
<!--<DataGridTextColumn Header="回复-长度" Binding="{Binding WCSReplyLength}"/>
<DataGridTextColumn Header="回复-宽度" Binding="{Binding WCSReplyWidth}"/>-->
<DataGridTextColumn Header="W-高度" Binding="{Binding WCSReplyHeight}"/>
<DataGridTextColumn Header="W-目标地址" Binding="{Binding WCSReplyAddress}"/>
<DataGridTextColumn Header="P-报文" Binding="{Binding ArriveMessage}"/>
<DataGridTextColumn Header="P-结果" Binding="{Binding ArriveResult}"/>
<DataGridTextColumn Header="P-读码器" Binding="{Binding ArriveRealAddress}"/>
<DataGridTextColumn Header="P-分配地址" Binding="{Binding ArriveAllcationAddress}"/>
<DataGridTextColumn Header="P-条码" Binding="{Binding ArriveBarcode}"/>
<DataGridTextColumn Header="W-报文" Binding="{Binding WCSACKMessage}"/>
<DataGridTextColumn Header="W-装载" Binding="{Binding WCSACKLoadStatus}"/>
<DataGridTextColumn Header="W-读码器" Binding="{Binding WCSACKNumber}"/>
</DataGrid.Columns>
</DataGrid>
</StackPanel>
</ScrollViewer>
</Border>
</TabItem>
</TabControl>
</Grid>
</Grid>
</TabItem>
</TabControl>
</Grid>
</DockPanel>
</win:BaseWindow>