2025-03-28 09:49:56 +08:00

257 lines
25 KiB
XML

<Window xmlns:TouchCashier="clr-namespace:TouchCashier" x:Class="TouchCashier.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:wfi="clr-namespace:System.Windows.Forms.Integration;assembly=WindowsFormsIntegration"
xmlns:winForms="clr-namespace:System.Windows.Forms;assembly=System.Windows.Forms"
xmlns:input="clr-namespace:System.Windows.Input;assembly=PresentationCore"
Title="驿商统一收银系统" Height="768" Width="1024" HorizontalAlignment="Stretch"
VerticalAlignment="Stretch" Topmost="True" Background="Transparent" WindowState="Maximized"
WindowStartupLocation="CenterScreen" BorderThickness="1" AllowsTransparency="True" WindowStyle="None"
PreviewKeyDown="Window_KeyDown" Loaded="Window_Loaded">
<Window.Resources>
<Style TargetType="{x:Type ProgressBar}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ProgressBar}" >
<Grid MinHeight="10" MinWidth="200">
<Border x:Name="PART_Track" CornerRadius="0" BorderBrush="#109EED" BorderThickness="0" Background="#FFCDCDCD" />
<Border x:Name="PART_Indicator" CornerRadius="0" BorderBrush="#109EED" BorderThickness="0" HorizontalAlignment="Left" >
<Border.Background>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0" Opacity="0.8">
<GradientStop Color="#FF1E7AD6" Offset="0"/>
<GradientStop Color="#FF1E7AD6" Offset="0.5"/>
<GradientStop Color="#FF1E7AD6" Offset="1"/>
</LinearGradientBrush>
</Border.Background>
</Border>
</Grid>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</Window.Resources>
<Grid>
<Viewbox StretchDirection="UpOnly" Margin="60,56" MinHeight="652" MinWidth="902">
<Border BorderBrush="#FFD3C9C9" CornerRadius="1" BorderThickness="1" MinHeight="652" MinWidth="902">
<Grid Background="White" >
<Grid Style="{StaticResource ResourceKey=TitleStyle}" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Height="650" Width="900">
<Grid.RowDefinitions>
<RowDefinition Height="150" />
<RowDefinition Height="50" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<Grid Grid.Row="0" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Grid.Background>
<ImageBrush ImageSource="/libESImage;Component/Image/基础/背景login.png"/>
</Grid.Background>
<Image Stretch="None" Margin="155,0,628,0" x:Name="img_logo" VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
<TextBlock Text="驿商统一收银系统" FontSize="55" x:Name="TxtSoftwareName" Margin="275,45,173,44" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Style="{DynamicResource FontStyle}">
<TextBlock.Effect>
<DropShadowEffect Color="#175d88" BlurRadius="8" ShadowDepth="4" Opacity="1"/>
</TextBlock.Effect>
<TextBlock.Foreground>
<LinearGradientBrush StartPoint="0.5,0" EndPoint="0.5,1">
<LinearGradientBrush.GradientStops>
<GradientStop Offset="3" Color="#309bf6" />
<GradientStop Color="#ffffff" />
</LinearGradientBrush.GradientStops>
</LinearGradientBrush>
</TextBlock.Foreground>
</TextBlock>
<Button Style="{StaticResource ResourceKey=ButtonUn}" Click="Button_Click" x:Name="btn_close" Margin="857,0,0,110" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Button.Background>
<ImageBrush ImageSource="/libESImage;Component/Image/新样式/菜单/关闭按钮.png" Stretch="None"/>
</Button.Background>
</Button>
<Button Style="{StaticResource ResourceKey=ButtonUn}" Click="Button_Click" x:Name="btnParameter" Margin="814,0,43,110" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Button.Background>
<ImageBrush ImageSource="/libESImage;Component/Image/新样式/菜单/设置.png" Stretch="None"/>
</Button.Background>
</Button>
<Button Style="{StaticResource ResourceKey=ButtonUn}" Click="Button_Click" x:Name="btnarport" Margin="770,0,86,110" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Button.Background>
<ImageBrush ImageSource="/libESImage;Component/Image/新样式/菜单/显示器.png" Stretch="None"/>
</Button.Background>
</Button>
<Button Margin="725,0,130,110" Style="{StaticResource ResourceKey=ButtonUn}" Click="Button_Click" x:Name="btnScaveng" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Button.Background>
<ImageBrush ImageSource="/libESImage;Component/Image/Parameter/扫码配置.png" Stretch="None"/>
</Button.Background>
</Button>
<Button Margin="682,0,175,110" Style="{StaticResource ResourceKey=ButtonUn}" Click="Button_Click" x:Name="btnDownDate" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Button.Background>
<ImageBrush ImageSource="/libESImage;Component/Image/新样式/菜单/下载.png" Stretch="None"/>
</Button.Background>
</Button>
</Grid>
<Grid Grid.Row="1" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Border Grid.Row="0" Margin="20,0,20,0" BorderBrush="#FFF0F0F0" BorderThickness="0,1,0,1">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="478*"/>
<ColumnDefinition Width="13*"/>
<ColumnDefinition Width="271*"/>
<ColumnDefinition Width="198*"/>
</Grid.ColumnDefinitions>
<CheckBox Margin="0,12,151,11" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
Style="{StaticResource ResourceKey=CheckBoxStyle}" x:Name="cb_Key"
Content="键盘版[F2]" IsChecked="False" Click="CheckBox_Click" IsTabStop="False" Visibility="Visible"/>
<Border Margin="110,10,11,10" BorderBrush="#FFC1BBBB" HorizontalAlignment="Stretch"
VerticalAlignment="Stretch" BorderThickness="1,0,0,0"/>
<CheckBox Margin="120,12,16,11" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
Style="{StaticResource ResourceKey=CheckBoxStyle}" x:Name="cb_Touch"
Content="触屏版[F2]" IsChecked="False" Click="CheckBox_Click" IsTabStop="False" Visibility="Visible"/>
<Border Margin="230,10,11,10" BorderBrush="#FFC1BBBB" HorizontalAlignment="Stretch"
VerticalAlignment="Stretch" BorderThickness="1,0,0,0"/>
<CheckBox Margin="240,12,71,11" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
Style="{StaticResource ResourceKey=CheckBoxStyle}" x:Name="cb_SelfTouch"
Content="自助版[F2]" IsChecked="False" Click="CheckBox_Click" IsTabStop="False"/>
<Border Margin="0,10,11,10" BorderBrush="#FFC1BBBB" HorizontalAlignment="Stretch"
VerticalAlignment="Stretch" BorderThickness="1,0,0,0" Grid.Column="1" />
<Button Margin="-260,1,7,1" Click="Button_Click" x:Name="btn_report" Grid.Column="2"
Style="{StaticResource ResourceKey=ButtonPay}" FontSize="16" Width="150"
Background="#ffffff" Height="46" VerticalAlignment="Center" Grid.Row="0" Focusable="False">
<Button.Template>
<ControlTemplate>
<Grid Background="#ffffff" x:Name="Grid_menu">
<Image Stretch="Uniform" Margin="0,6,100,0" Source="/libESImage;Component/Image/新样式/顶部菜单/系统菜单优化.png"/>
<TextBlock Text="报表查询[F5]" Margin="50,14,0,14" FontSize="16" VerticalAlignment="Center"/>
</Grid>
</ControlTemplate>
</Button.Template>
</Button>
<Button Grid.Row="0" Margin="50,1,7,1" Click="Button_Click" x:Name="btn_Test" Grid.Column="2"
Style="{StaticResource ResourceKey=ButtonPay}" FontSize="16" Width="150" IsEnabled="True"
Background="#ffffff" Height="46" VerticalAlignment="Center" Focusable="False" Visibility="Visible">
<Button.Template>
<ControlTemplate>
<Grid Background="#ffffff" x:Name="Grid_menu">
<Image Stretch="Uniform" Margin="0,6,100,0" Source="/libESImage;Component/Image/新样式/顶部菜单/系统菜单优化.png"/>
<TextBlock Text="收银练习[F6]" Margin="50,14,0,14" FontSize="16" VerticalAlignment="Center"/>
</Grid>
</ControlTemplate>
</Button.Template>
</Button>
<Button Margin="118,0,0,0" Style="{DynamicResource ResourceKey=ButtonPay}" Click="Button_Click" x:Name="btn_face" Grid.Column="3">
<Button.Background>
<ImageBrush ImageSource="/libESImage;Component/Image/支付/人脸识别.png" Stretch="None"/>
</Button.Background>
</Button>
<Button Margin="70,0,48,0" Style="{DynamicResource ResourceKey=ButtonPay}" Click="Button_Click" x:Name="btn_finger" Grid.Column="3">
<Button.Background>
<ImageBrush ImageSource="/libESImage;Component/Image/支付/指纹icon.png" Stretch="None"/>
</Button.Background>
</Button>
<Button Margin="22,0,96,0" Style="{DynamicResource ResourceKey=ButtonPay}" Click="Button_Click" x:Name="btn_user" Grid.Column="3">
<Button.Background>
<ImageBrush ImageSource="/libESImage;Component/Image/支付/账号.png" Stretch="None"/>
</Button.Background>
</Button>
</Grid>
</Border>
</Grid>
<Grid Grid.Row="2" Margin="0,0,0,0" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" x:Name="Grid_LoginUser" Visibility="Visible">
<Grid Margin="100,95,100,118" x:Name="Grid_User" HorizontalAlignment="Center" VerticalAlignment="Stretch">
<StackPanel Grid.Column="0" Orientation="Horizontal" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" x:Name="stp_title">
<Image Margin="50,4,0,0" Width="37" Height="35" VerticalAlignment="Top" x:Name="img_login" HorizontalAlignment="Stretch" Source="/libESImage;Component/Image/支付/账号.png"/>
<TextBlock Margin="10,12,0,0" Width="90" Text="账号登录" FontSize="20" VerticalAlignment="Top" HorizontalAlignment="Stretch"/>
</StackPanel>
<StackPanel Grid.Column="0" Orientation="Horizontal" Margin="40,45,55,25" Visibility="Collapsed" x:Name="stp_img" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<TouchCashier:LoadingTime />
<WindowsFormsHost Foreground="{x:Null}" Margin="0,0,0,0" Width="265" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Visibility="Collapsed">
<winForms:PictureBox SizeMode="Zoom" x:Name="imga" />
</WindowsFormsHost>
</StackPanel>
<StackPanel Grid.Column="0" Orientation="Horizontal" x:Name="stp_name" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Image Margin="80,65,0,0" Width="28" Height="28" VerticalAlignment="Top" x:Name="img_uname" HorizontalAlignment="Stretch" Source="/libESImage;Component/Image/浙江/账号.png"/>
<TextBlock Text="账号:" FontSize="20" Margin="5,68,0,0" Foreground="#000000" Height="26" VerticalAlignment="Top" HorizontalAlignment="Stretch"/>
<TextBox Margin="12,64,0,0" GotFocus="TextBox_GotFocus" VerticalContentAlignment="Center" Background="#f1f1f1"
HorizontalAlignment="Stretch" ContextMenu="{x:Null}" x:Name="TxtUserName" KeyDown="TextBox_KeyDown"
Width="199" FontSize="20" InputMethod.IsInputMethodEnabled="False" Height="34" VerticalAlignment="Top" TabIndex="1"/>
</StackPanel>
<StackPanel Grid.Column="0" Orientation="Horizontal" HorizontalAlignment="Stretch" x:Name="stp_pwd">
<Image Margin="80,127,0,0" Width="28" Height="29" VerticalAlignment="Top" x:Name="img_pwd" HorizontalAlignment="Stretch" Source="/libESImage;Component/Image/浙江/密码.png"/>
<TextBlock Text="密码:" FontSize="20" Margin="5,131,0,0" Foreground="#000000" Height="25" VerticalAlignment="Top" HorizontalAlignment="Stretch" />
<PasswordBox FontSize="20" GotFocus="TextBox_GotFocus" VerticalContentAlignment="Center" HorizontalAlignment="Stretch" Margin="12,127,0,0"
Background="#f1f1f1" x:Name="TxtPwd" Width="199" KeyDown="TxtPwd_KeyDown" PasswordChar="*" InputMethod.IsInputMethodEnabled="False" Height="34"
VerticalAlignment="Top" IsTabStop="False" ContextMenu="{x:Null}"/>
</StackPanel>
<StackPanel Grid.Column="0" Orientation="Horizontal" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Width="Auto">
<TextBlock Margin="0,177,0,0" FontSize="16" HorizontalAlignment="Center" TextAlignment="Center" x:Name="TxtMessage" Foreground="Red" MinWidth="450" Height="25" VerticalAlignment="Top"/>
</StackPanel>
</Grid>
<StackPanel Grid.Column="0" Orientation="Vertical" Margin="0,0,0,10" HorizontalAlignment="Left" VerticalAlignment="Bottom">
<TextBlock Width="200" Margin="15,10,10,0" x:Name="TxtVersion" FontSize="16" TextAlignment="Left" VerticalAlignment="Center" />
<TextBlock Width="200" Margin="15,3,10,0" x:Name="TxtExpiryDate" FontSize="16" TextAlignment="Left" VerticalAlignment="Center" Visibility="Collapsed"/>
<Button Cursor="Hand" x:Name="btn_login" Margin="24,190,0,49" Background="#FF0984FF" Content="登录" FontSize="20" Click="Button_Click"
Width="106" Foreground="White" Visibility="Collapsed" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"/>
</StackPanel>
</Grid>
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Visibility="Collapsed" x:Name="Grid_LoginFinger">
<Grid Margin="265,95,263,118" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<StackPanel Orientation="Horizontal" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="100,0,0,0">
<Image Margin="3,4,0,0" Width="37" Height="35" VerticalAlignment="Top" x:Name="img_loginfinger" HorizontalAlignment="Stretch" Source="/libESImage;Component/Image/支付/指纹icon.png"/>
<TextBlock Margin="10,12,0,0" Width="90" Text="指纹登录" FontSize="20" VerticalAlignment="Top" HorizontalAlignment="Stretch"/>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="100,0,0,0">
<Image Source="/libESImage;Component/Image/基础/静态指纹.png" Width="132" Margin="20,70,0,0" x:Name="img_finger" Height="105" VerticalAlignment="Top" HorizontalAlignment="Stretch"/>
<WindowsFormsHost Width="130" Foreground="{x:Null}" Margin="20,70,0,0" Height="105" VerticalAlignment="Top" HorizontalAlignment="Stretch" x:Name="gif_finger" Visibility="Collapsed">
<winForms:PictureBox x:Name="PictureFigr" SizeMode="Zoom"/>
</WindowsFormsHost>
</StackPanel>
<StackPanel Grid.Column="0" Orientation="Horizontal" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<TextBlock Margin="0,195,30,0" FontSize="18" HorizontalAlignment="Stretch" TextAlignment="Center" x:Name="TxtState" Foreground="Red" Width="370" Height="30" VerticalAlignment="Top"/>
</StackPanel>
</Grid>
</Grid>
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Visibility="Collapsed" x:Name="Grid_LoginFace">
<Grid Margin="265,95,263,118" x:Name="Grid_Face" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Grid.Row="1">
<StackPanel Orientation="Horizontal" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="100,0,0,0">
<Image Margin="3,4,0,0" Width="37" Height="35" VerticalAlignment="Top" HorizontalAlignment="Stretch" Source="/libESImage;Component/Image/支付/人脸识别.png"/>
<TextBlock Margin="10,12,0,0" Width="90" Text="人脸登录" FontSize="20" VerticalAlignment="Top" HorizontalAlignment="Stretch"/>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="100,0,0,0">
<Image Source="/libESImage;Component/Image/基础/静态人脸.png" Width="129" Margin="20,70,0,0" x:Name="img_face" Height="105" VerticalAlignment="Top" HorizontalAlignment="Stretch"/>
<WindowsFormsHost Width="130" Foreground="{x:Null}" Margin="20,70,0,0" Height="105" VerticalAlignment="Top" Visibility="Collapsed" HorizontalAlignment="Stretch" x:Name="gif_face">
<winForms:PictureBox x:Name="PictureFace" SizeMode="Zoom"/>
</WindowsFormsHost>
</StackPanel>
<StackPanel Grid.Column="0" Orientation="Horizontal" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<TextBlock Margin="0,195,0,0" FontSize="18" TextAlignment="Center" x:Name="TxtStateFace" Foreground="Red" Width="370" Height="25" VerticalAlignment="Top" HorizontalAlignment="Stretch"/>
</StackPanel>
</Grid>
</Grid>
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" x:Name="GridLoad" Visibility="Collapsed">
<Grid Margin="265,95,263,118" x:Name="GridUser" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<TouchCashier:LoadingTime Margin="0,0,0,55" />
<TextBlock Margin="0,195,0,0" Text="正在自动登录请稍候...." x:Name="TxtMsg" FontSize="20" TextAlignment="Center"/>
</Grid>
</Grid>
<Grid Grid.ColumnSpan="3" Margin="240,453,240,0" x:Name="Grid_keyboard" Focusable="False">
<Grid.Background>
<ImageBrush ImageSource="/libESImage;Component/Image/基础/bacgs.png"/>
</Grid.Background>
<TouchCashier:DigitalKeyboard Margin="25,20,20,10" />
</Grid>
<TextBox Margin="0,448,0,0" x:Name="txt_focus" HorizontalAlignment="Right" VerticalAlignment="Top" Width="444" Height="0"/>
<TextBlock Margin="196,44,198,382" TextAlignment="Center" Foreground="Red" VerticalAlignment="Center" FontSize="18" x:Name="TxtLogin" Grid.ColumnSpan="3" HorizontalAlignment="Stretch"/>
<WindowsFormsHost Foreground="{x:Null}" HorizontalAlignment="Stretch" Margin="275,10,240,0" Height="56" VerticalAlignment="Top" Focusable="False" x:Name="Grid_wf" Visibility="Collapsed">
<winForms:PictureBox x:Name="imgload" SizeMode="Zoom"/>
</WindowsFormsHost>
</Grid>
</Grid>
<Grid x:Name="Grid_Load" Visibility="Collapsed">
<Grid Background="Black" Opacity="0.5"/>
<Grid VerticalAlignment="Center" HorizontalAlignment="Center" Height="300">
<TouchCashier:LoadingTime />
<TextBlock Text="正在加载,请稍候..." TextAlignment="Center" Foreground="White" FontSize="20" Height="30" Margin="0,260,0,0" VerticalAlignment="Top" x:Name="TxtLoad"></TextBlock>
</Grid>
<ProgressBar Margin="299,474,299,148" Maximum="100" x:Name="pbrDown"/>
</Grid>
</Grid>
</Border>
</Viewbox>
</Grid>
</Window>