|
- <UserControl x:Class="BPASmartClient.MilkWithTea.View.ParameterSetting"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:local="clr-namespace:BPASmartClient.MilkWithTea.View"
- xmlns:vm="clr-namespace:BPASmartClient.MilkWithTea.ViewModel"
- mc:Ignorable="d"
- d:DesignHeight="900" d:DesignWidth="1400" Background="Transparent" >
- <UserControl.DataContext>
- <vm:PatrameterSettiongViewModel/>
- </UserControl.DataContext>
- <UserControl.Resources>
-
- </UserControl.Resources>
- <Grid Background="#F3F6F9" Margin="20" >
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="*"/>
- <RowDefinition Height="*"/>
- <RowDefinition Height="*"/>
- </Grid.RowDefinitions>
- <GroupBox Grid.ColumnSpan="2" Header="参数调试" FontSize="20" Style="{StaticResource GroupBoxStyle1}" Padding="40,20" Margin="20,10">
- <GroupItem>
- <Grid>
- <Grid.RowDefinitions>
- <RowDefinition Height="*"/>
- <RowDefinition Height="20"/>
- <RowDefinition Height="*"/>
- </Grid.RowDefinitions>
- <StackPanel Orientation="Horizontal">
- <TextBlock Text="通道口:"/>
- <ComboBox ItemsSource="{Binding materialPosions}"
- SelectedValue="{Binding MaterialID ,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
- Margin="10,0" Width="120 " Style="{StaticResource cmbstyle}"/>
- <TextBlock Text="出料量:" Margin="10,0,0,0" />
- <TextBox Text="{Binding OutMaterailWeight}" Width="60" Margin="10,0" VerticalContentAlignment="Center"/>
- <TextBlock Text="g" Margin="2,0"/>
- <Button Content="出料" Style="{StaticResource buttonNormal}" Height="36" Width="100" Margin="30,0" Command="{Binding OutMaterailCommad}"/>
- <!--<TextBlock Text="转盘位置:" Margin="60,0,10,0"/>-->
- <!--<ComboBox ItemsSource="{Binding TurntablePosion}"
- SelectedIndex="{Binding TurntableID,Mode=TwoWay ,UpdateSourceTrigger=PropertyChanged}"
- Margin="10,0" Width="100 " Style="{StaticResource cmbstyle}"/>
- <Button Content="转动" Style="{StaticResource buttonNormal}" Height="36" Width="80" Margin="30,0"
- Command="{Binding TurntableCommad}"/>-->
- </StackPanel>
- <CheckBox Grid.Row="2" Content="禁用本地奶茶下单" HorizontalAlignment="Left" Margin="0,10"
- HorizontalContentAlignment="Center" VerticalContentAlignment="Center"
- IsChecked="{Binding IsEnable}"/>
- </Grid>
- </GroupItem>
- </GroupBox>
-
- <GroupBox Grid.ColumnSpan="2" Grid.Row="1" Header="通道矫正" FontSize="20" BorderThickness="10" Style="{StaticResource GroupBoxStyle1}" Margin="20,10">
- <GroupItem>
- <Grid Margin="20">
- <Grid.RowDefinitions>
- <RowDefinition Height="40"/>
- <RowDefinition Height="100"/>
- <RowDefinition Height="*"/>
- </Grid.RowDefinitions>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="140"/>
- <ColumnDefinition Width="140"/>
- <ColumnDefinition Width="140"/>
- <ColumnDefinition Width="140"/>
- <ColumnDefinition Width="140"/>
- <ColumnDefinition Width="140"/>
- <ColumnDefinition Width="140"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <TextBlock Text="通道" />
- <TextBlock Text="名称" Grid.Column="1"/>
- <TextBlock Text="开关" Grid.Column="2"/>
- <TextBlock Text="校正后的重量" Grid.Column="5"/>
- <TextBlock Text="出料时间" Grid.Column="3"/>
-
- <ComboBox Grid.Row="1" Width="100" Style="{StaticResource cmbstyle}" ItemsSource="{Binding materialPosions}" Height="30"
- SelectedIndex="{Binding CorrectPassway ,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" SelectionChanged="ComboBox_SelectionChanged" />
- <TextBlock Grid.Row="1" Grid.Column="1" ></TextBlock>
- <CheckBox x:Name="OpenIsCheck"
- Grid.Row="1" Grid.Column="2" Style="{StaticResource OpenCheckBoxStyle1}" Height="40"
- IsChecked="{Binding PasswayIsOpen,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
- Command="{Binding OpenPasswayCommand}"/>
- <TextBox Text="{Binding CorrectMatetailWeight,Mode=TwoWay}" Grid.Row="1" Grid.Column="5" Width="60" Height="30"></TextBox>
- <TextBlock Text="克" Grid.Row="1" Grid.Column="5" HorizontalAlignment="Right" Margin="0,0,10,0"></TextBlock>
- <TextBox Text="{Binding OutTime}" Grid.Row="1" Grid.Column="3" Width="60" Height="30"></TextBox>
- <TextBlock Text="秒" Grid.Row="1" Grid.Column="3" HorizontalAlignment="Right" Margin="0,0,16,0"></TextBlock>
- <TextBlock Text="矫正方法" Grid.Column="7"/>
- <Button Content="开始矫正" Style="{StaticResource buttonNormal}"
- Grid.Row="1" Grid.Column="4" HorizontalAlignment="Center"
- Height="40" Width="120"
- Command="{Binding CheckPasswayCommad}"/>
- <Button Content="确认重量" Style="{StaticResource buttonNormal}"
- Grid.Row="1" Grid.Column="6" HorizontalAlignment="Center"
- Height="40" Width="120"
- Command="{Binding CheckMaterailWeightCommand}"/>
- <TextBlock Text=" 准备好校正电子秤,打开需要校正的通道,点击“开始校正”的按钮,填入校正后的重量并确认。"
- Margin="6,0" TextWrapping="Wrap"
- Grid.Column="7" Grid.Row="1" />
- </Grid>
- </GroupItem>
- </GroupBox>
- <GroupBox Grid.ColumnSpan="2" Grid.Row="2" Header="设备配置" FontSize="20" BorderThickness="10" Style="{StaticResource GroupBoxStyle1}" Margin="20,10">
- <Grid Margin="30,5">
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="100"/>
- <ColumnDefinition Width="90"/>
- <ColumnDefinition Width="110"/>
- <ColumnDefinition Width="90"/>
- <ColumnDefinition Width="60"/>
- <ColumnDefinition Width="60"/>
- <ColumnDefinition/>
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="*"/>
- <RowDefinition Height="*"/>
- <RowDefinition Height="*"/>
- <RowDefinition Height="*"/>
- <RowDefinition Height="10"/>
- </Grid.RowDefinitions>
- <TextBlock Text="店铺名称:" Grid.ColumnSpan="2" FontSize="22" Height="28" Width="94" HorizontalAlignment="Left" Margin="20,0"/>
- <TextBox Text="{Binding ShopName}" Grid.Column="2" Grid.ColumnSpan="2" Margin="-20,10,30,10" VerticalContentAlignment="Center"/>
- <TextBlock Text="店铺ID:" Grid.Row="1" Height="23" Width="60" HorizontalAlignment="Left" Margin="20,0"/>
- <TextBlock Text="设备ID:" Grid.Column="2" Grid.Row="1" Height="23" Width="60" />
-
- <TextBox Text="{Binding ShopID}" Width="60" Grid.Column="1" Grid.Row="1" HorizontalAlignment="Left" VerticalContentAlignment="Center" Margin="0,12"/>
- <TextBox Text="{Binding DeviceID}" Width="60" Grid.Column="3" Grid.Row="1" HorizontalAlignment="Left" VerticalContentAlignment="Center" Margin="0,12"/>
-
- <RadioButton Content="网口" GroupName="a" Grid.Row="2" HorizontalAlignment="Center" VerticalAlignment="Center" VerticalContentAlignment="Center"
- Command="{Binding ChangeCommunationCommand}"/>
- <StackPanel Grid.Row="2" Grid.Column="1" Grid.ColumnSpan="3" Orientation="Horizontal" Visibility="{Binding VsIP}"
- HorizontalAlignment="Center" VerticalAlignment="Center">
- <TextBlock Text="IP:" Height="23" Margin="20,0"/>
- <TextBox Text="{Binding PLCAdress}" Margin="0,10,30,10" Width="160"
- VerticalContentAlignment="Center"/>
- </StackPanel>
- <RadioButton Content="串口" GroupName="a" Grid.Row="3" HorizontalAlignment="Center" VerticalAlignment="Center" VerticalContentAlignment="Center"
- IsChecked="{Binding IsPort}" Command="{Binding ChangeCommunationCommand}"/>
- <StackPanel Grid.Row="3" Grid.Column="1" Grid.ColumnSpan="3" Orientation="Horizontal" Visibility="{Binding VsPort}">
- <TextBlock Text="串口号:" />
- <ComboBox Style="{DynamicResource cmbstyle}" Height="26" Width="100" ItemsSource="{Binding Ports}"
- SelectedValue="{Binding Prot}"/>
- </StackPanel>
- <Button Style="{StaticResource buttonNormal}"
-
- Grid.Column="4" Grid.ColumnSpan="2" Grid.Row="0" Grid.RowSpan="3"
- Height="130" Width="80"
- Command="{Binding SaveDevicesCommand}">
- <Grid>
- <Grid.RowDefinitions>
- <RowDefinition Height="*"/>
- <RowDefinition Height="10"/>
- <RowDefinition Height="*"/>
- </Grid.RowDefinitions>
- <TextBlock Text="保存" TextWrapping="Wrap" Foreground="White" FontSize="20" />
- <TextBlock Text="配置" TextWrapping="Wrap" Foreground="White" FontSize="20" Grid.Row="2"/>
- </Grid>
-
- </Button>
- </Grid>
- </GroupBox>
- </Grid>
- </UserControl>
|