123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353 |
- <Window
- 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:input="clr-namespace:System.Windows.Input;assembly=PresentationCore"
- xmlns:local="clr-namespace:AwInitilizer"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:resx="clr-namespace:AwInitilizer.Resx"
- x:Name="uxManinWindow"
- Title="Initializer"
- Width="1920"
- Height="1080"
- d:DataContext="{d:DesignInstance Type=local:MainViewModel}"
- input:InputMethod.IsInputMethodEnabled="False"
- Background="#FF363535"
- PreviewKeyDown="MainWindow_PreviewKeyDown"
- WindowStartupLocation="CenterScreen"
- WindowState="Maximized"
- mc:Ignorable="d"
- x:Class="AwInitilizer.MainWindow">
- <Window.Resources />
- <Viewbox>
- <StackPanel Orientation="Vertical">
- <StackPanel Orientation="Horizontal">
- <StackPanel
- Width="400"
- Margin="10,0,0,0"
- Orientation="Vertical">
- <GroupBox>
- <GroupBox.Header>
- <Label
- FontSize="16"
- Content="{x:Static resx:AppResources.Account}"
- Foreground="White" />
- </GroupBox.Header>
- <StackPanel Orientation="Vertical">
- <Button
- Width="100"
- Click="Logout_Click"
- IsEnabled="{Binding IsInputLock}">
- <Label Content="{x:Static resx:AppResources.Logout}" />
- </Button>
- <StackPanel
- Height="30"
- Margin="0,10,0,10"
- Orientation="Horizontal">
- <Grid Width="178">
- <Label
- HorizontalAlignment="Center"
- FontSize="16"
- Content="{x:Static resx:AppResources.UserID}"
- Foreground="White" />
- </Grid>
- <TextBox
- Width="200"
- VerticalContentAlignment="Center"
- Text="{Binding UserID}"
- FontSize="16"
- IsEnabled="{Binding IsInputLock}"
- IsReadOnly="True"
- TextAlignment="Center" />
- </StackPanel>
- <StackPanel
- Height="30"
- Margin="0,0,0,10"
- Orientation="Horizontal">
- <Grid Width="178">
- <Label
- HorizontalAlignment="Center"
- FontSize="16"
- Content="{x:Static resx:AppResources.WorkOrder}"
- Foreground="White" />
- </Grid>
- <TextBox
- Width="200"
- VerticalContentAlignment="Center"
- Text="{Binding WorkOrder}"
- FontSize="16"
- IsEnabled="{Binding IsInputLock}"
- IsReadOnly="True"
- KeyDown="WorkOrder_KeyDown"
- TextAlignment="Center"
- TextChanged="WorkOrder_TextChanged" />
- </StackPanel>
- </StackPanel>
- </GroupBox>
- <GroupBox>
- <GroupBox.Header>
- <Label
- FontSize="16"
- Content="{x:Static resx:AppResources.BarcodeSetting}"
- Foreground="White" />
- </GroupBox.Header>
- <StackPanel Orientation="Vertical">
- <StackPanel Height="30" Orientation="Horizontal">
- <Grid Width="178">
- <Label
- HorizontalAlignment="Center"
- FontSize="16"
- Content="{x:Static resx:AppResources.ModelName}"
- Foreground="White" />
- </Grid>
- <TextBox
- x:Name="uxModelName"
- Width="200"
- VerticalContentAlignment="Center"
- Text="{Binding ModelName}"
- FontSize="16"
- IsEnabled="{Binding IsInputLock}"
- IsReadOnly="True"
- TextAlignment="Center" />
- </StackPanel>
- <StackPanel
- Height="30"
- Margin="0,10,0,10"
- Orientation="Horizontal">
- <Grid Width="178">
- <Label
- HorizontalAlignment="Center"
- FontSize="16"
- Content="{x:Static resx:AppResources.SerialNumber}"
- Foreground="White" />
- </Grid>
- <TextBox
- x:Name="uxSerialNumber"
- Width="200"
- VerticalContentAlignment="Center"
- Text="{Binding SerialNumber}"
- FontSize="16"
- IsEnabled="{Binding IsInputLock}"
- IsReadOnly="True"
- TextAlignment="Center" />
- </StackPanel>
- <StackPanel
- Height="30"
- Margin="0,0,0,10"
- Orientation="Horizontal">
- <Grid Width="178">
- <Label
- HorizontalAlignment="Center"
- FontSize="16"
- Content="{x:Static resx:AppResources.SimStatus}"
- Foreground="White" />
- </Grid>
- <CheckBox
- x:Name="uxIsSimCheckEnabled"
- VerticalAlignment="Center"
- IsChecked="{Binding IsSimInsert}"
- IsEnabled="{Binding IsInputLock}"
- IsHitTestVisible="False" />
- <CheckBox
- x:Name="uxIsSimCheckEnabled2"
- VerticalAlignment="Center"
- IsChecked="{Binding IsSubSimInsert}"
- IsEnabled="{Binding IsInputLock}"
- IsHitTestVisible="False" />
- </StackPanel>
- <StackPanel
- Height="30"
- Margin="0,0,0,10"
- Orientation="Horizontal">
- <Grid Width="178">
- <Label
- HorizontalAlignment="Center"
- FontSize="16"
- Content="{x:Static resx:AppResources.ICCID}"
- Foreground="White" />
- </Grid>
- <TextBox
- x:Name="uxICCID"
- Width="200"
- VerticalContentAlignment="Center"
- Text="{Binding UiSimICCID, Mode=OneWay}"
- FontSize="16"
- IsReadOnly="True"
- TextAlignment="Center">
- <TextBox.IsEnabled>
- <MultiBinding Converter="{StaticResource booleanAndConverter}">
- <Binding Path="IsSimInsert" />
- <Binding Path="IsInputLock" />
- </MultiBinding>
- </TextBox.IsEnabled>
- </TextBox>
- </StackPanel>
- <StackPanel
- Height="30"
- Margin="0,0,0,10"
- Orientation="Horizontal">
- <Grid Width="178">
- <Label
- HorizontalAlignment="Center"
- FontSize="16"
- Content="{x:Static resx:AppResources.IMSI}"
- Foreground="White" />
- </Grid>
- <TextBox
- x:Name="uxIMSI"
- Width="200"
- VerticalContentAlignment="Center"
- Text="{Binding UiSimIMSI, Mode=OneWay}"
- FontSize="16"
- IsReadOnly="True"
- TextAlignment="Center">
- <TextBox.IsEnabled>
- <MultiBinding Converter="{StaticResource booleanAndConverter}">
- <Binding Path="IsSimInsert" />
- <Binding Path="IsInputLock" />
- </MultiBinding>
- </TextBox.IsEnabled>
- </TextBox>
- </StackPanel>
- <StackPanel
- Height="30"
- Margin="0,0,0,10"
- Orientation="Horizontal">
- <Grid Width="178">
- <Label
- HorizontalAlignment="Center"
- FontSize="16"
- Content="{x:Static resx:AppResources.DisableAuth}"
- Foreground="White" />
- </Grid>
- <CheckBox
- VerticalAlignment="Center"
- IsChecked="{Binding IsDisableAuthRequired}"
- IsEnabled="{Binding IsInputLock}"
- IsHitTestVisible="False" />
- </StackPanel>
- </StackPanel>
- </GroupBox>
- </StackPanel>
- <StackPanel
- Width="400"
- Margin="10,0,0,0"
- Orientation="Vertical">
- <GroupBox>
- <GroupBox.Header>
- <Label
- FontSize="16"
- Content="{x:Static resx:AppResources.FirmwareVersion}"
- Foreground="White" />
- </GroupBox.Header>
- <DataGrid
- Height="335"
- Margin="10"
- AutoGenerateColumns="False"
- CanUserSortColumns="False"
- IsEnabled="{Binding IsInputLock}"
- ItemsSource="{Binding FirmwareUpdateModels}">
- <DataGrid.Columns>
- <DataGridTextColumn
- Width="150"
- MinWidth="50"
- Binding="{Binding Path=Module}"
- Header="{x:Static resx:AppResources.FirmwareVersionHeaderName}"
- IsReadOnly="True" />
- <DataGridTextColumn
- Width="150"
- MinWidth="70"
- Binding="{Binding Path=Version}"
- Header="{x:Static resx:AppResources.FirmwareVersionHeaderVersion}"
- IsReadOnly="True" />
- <!-- " DataGridTextColumn Header="File name" Binding="{Binding Path=FirmwareFileName}" IsReadOnly="False"/ -->
- </DataGrid.Columns>
- </DataGrid>
- </GroupBox>
- </StackPanel>
- <Grid Margin="10,0,0,0">
- <Grid.RowDefinitions>
- <RowDefinition Height="*" />
- <RowDefinition Height="30" />
- <RowDefinition Height="*" />
- </Grid.RowDefinitions>
- <Button
- x:Name="uxStartBtn"
- Grid.Row="0"
- Margin="30"
- Click="StartInit_Click">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border
- Background="White"
- BorderBrush="Gray"
- BorderThickness="2"
- CornerRadius="10">
- <Border.Effect>
- <DropShadowEffect ShadowDepth="10" />
- </Border.Effect>
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" />
- </Border>
- </ControlTemplate>
- </Button.Template>
- <Button.IsEnabled>
- <MultiBinding Converter="{StaticResource booleanAndConverter}">
- <Binding Path="IsInputLock" />
- <Binding Path="IsInputCheckpassed" />
- </MultiBinding>
- </Button.IsEnabled>
- <Label FontSize="36" Content="{x:Static resx:AppResources.StartProcedure}" />
- </Button>
- <StackPanel Grid.Row="1" Orientation="Vertical">
- <StackPanel
- HorizontalAlignment="Center"
- VerticalAlignment="Center"
- Orientation="Horizontal">
- <ProgressBar
- x:Name="uxProgress"
- Width="250"
- Height="20"
- VerticalAlignment="Center"
- Maximum="100"
- Minimum="0" />
- <Label
- x:Name="uxProgressRate"
- FontSize="16"
- Content="0%"
- Foreground="White" />
- </StackPanel>
- </StackPanel>
- <Grid
- x:Name="uxStatusContainer"
- Grid.Row="2"
- Margin="30"
- Background="White">
- <Label
- x:Name="uxStatus"
- HorizontalAlignment="Center"
- VerticalAlignment="Center"
- FontSize="36"
- Content="Idle"
- Foreground="Black" />
- </Grid>
- </Grid>
- </StackPanel>
- <Label
- x:Name="uxStatusBar"
- Margin="0,10,0,0"
- HorizontalAlignment="Center"
- FontSize="36"
- Content=""
- Foreground="White" />
- </StackPanel>
- </Viewbox>
- </Window>
|