Files
DE70/Admin/AdminWindow.xaml
T

96 lines
4.0 KiB
XML

<hc:Window x:Class="SafeBagDE70.Admin.AdminWindow"
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:local="clr-namespace:SafeBagDE70.Admin"
xmlns:hc="https://handyorg.github.io/handycontrol"
mc:Ignorable="d"
ShowInTaskbar="False"
ShowNonClientArea="False"
Title="AdminWindow" Height="1024" Width="1280">
<Grid>
<!-- Define Rows and Columns -->
<Grid.RowDefinitions>
<RowDefinition Height="50"/>
<!-- Top Bar -->
<RowDefinition Height="*"/>
<!-- Main Content Area -->
<RowDefinition Height="150"/>
<!-- Footer -->
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="200"/>
<!-- Sidebar -->
<ColumnDefinition Width="*"/>
<!-- Main Content Area -->
</Grid.ColumnDefinitions>
<!-- Top Bar -->
<StackPanel Grid.Row="0" Grid.ColumnSpan="2" Orientation="Horizontal" Background="LightGray" Height="50">
<TextBlock Text="Admin Panel" VerticalAlignment="Center" Margin="10" Foreground="White" FontSize="20"/>
<Button Content="Log Out"
HorizontalAlignment="Right"
Margin="0,0,10,0"
Click="LogoutButton_Click"
Background="Red"
Foreground="White" Width="100"/>
</StackPanel>
<!-- Sidebar -->
<StackPanel Grid.Row="1" Grid.Column="0" Background="LightGray" VerticalAlignment="Top">
<Button
Content="Sự kiện"
HorizontalAlignment="Stretch"
Height="40"
Margin="10"
Click="DashboardButton_Click"/>
<Button
Content="Quản lý gian hàng"
HorizontalAlignment="Stretch"
Height="40"
Margin="10"
Click="UserManagementButton_Click"/>
<Button
Content="Thiết lập"
HorizontalAlignment="Stretch"
Height="40"
Margin="10"
Click="SettingsButton_Click"/>
<Button
Content="Cấu hình CDM"
HorizontalAlignment="Stretch"
Height="40"
Margin="10"
Padding="10"
Click="ConfigurationButton_Click"/>
<Button
Content="Tắt app"
HorizontalAlignment="Stretch"
Height="40"
Margin="10"
Padding="10"
Click="btnShutdownApp_Click"/>
<Button
Content="Khởi động lại app"
HorizontalAlignment="Stretch"
Height="40"
Margin="10"
Padding="10"
Click="btnRestartApp_Click"/>
</StackPanel>
<!-- Main Content Area -->
<ContentControl Grid.Row="1" Grid.Column="1" x:Name="MainContentControl" Margin="10"/>
<!-- Footer -->
<StackPanel Grid.Row="2" Grid.ColumnSpan="2" Orientation="Horizontal" Background="LightGray">
<TextBlock Text="Admin Panel" VerticalAlignment="Center" Margin="10" Foreground="White" FontSize="14"/>
<TextBlock x:Name="lblCDMStatus" Text="{Binding CDMStatus}" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0" Foreground="Red" FontSize="20"/>
<TextBlock x:Name="lblPrinterStatus" Text="{Binding PrinterStatus}" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0" Foreground="Red" FontSize="20"/>
<TextBlock x:Name="lblSensorStatus" Text="{Binding SensorStatus}" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0" Foreground="Red" FontSize="20"/>
<TextBlock x:Name="lblDeviceStatus" Text="{Binding DeviceStatus}" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0" Foreground="Red" FontSize="20"/>
</StackPanel>
</Grid>
</hc:Window>