终端一体化运控平台
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

173 lines
8.0 KiB

  1. <UserControl
  2. x:Class="BPASmartClient.JXJFoodSmallStation.View.RecipeReceiveView"
  3. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  4. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  5. xmlns:control="clr-namespace:BPASmartClient.CustomResource.UserControls;assembly=BPASmartClient.CustomResource"
  6. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  7. xmlns:local="clr-namespace:BPASmartClient.JXJFoodSmallStation.View"
  8. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  9. xmlns:pry="clr-namespace:BPASmartClient.CustomResource.UserControls;assembly=BPASmartClient.CustomResource"
  10. xmlns:vm="clr-namespace:BPASmartClient.JXJFoodSmallStation.ViewModel"
  11. d:DesignHeight="450"
  12. d:DesignWidth="800"
  13. mc:Ignorable="d">
  14. <UserControl.Resources>
  15. <SolidColorBrush x:Key="BorderSolid" Color="#5523CACA" />
  16. <SolidColorBrush x:Key="FontColor" Color="#FF2AB2E7" />
  17. <SolidColorBrush x:Key="TitleFontColor" Color="#ddd" />
  18. <SolidColorBrush x:Key="CursorColor" Color="Aqua" />
  19. <SolidColorBrush x:Key="TitleBorderColor" Color="#FF2AB2E7" />
  20. <SolidColorBrush x:Key="TextBlockForeground" Color="#9934F7F7" />
  21. <Style x:Key="TextBlockStyle" TargetType="TextBlock">
  22. <Setter Property="FontFamily" Value="楷体" />
  23. <Setter Property="FontSize" Value="20" />
  24. <Setter Property="Background" Value="Transparent" />
  25. <!--<Setter Property="Foreground" Value="{StaticResource FontColor}" />-->
  26. <Setter Property="VerticalAlignment" Value="Center" />
  27. <Setter Property="HorizontalAlignment" Value="Center" />
  28. </Style>
  29. <Style x:Key="buttonStyle" TargetType="Button">
  30. <Setter Property="Background" Value="Transparent" />
  31. <Setter Property="FontSize" Value="16" />
  32. <Setter Property="Foreground" Value="Aqua" />
  33. <Setter Property="HorizontalAlignment" Value="Center" />
  34. <Setter Property="BorderThickness" Value="0" />
  35. </Style>
  36. </UserControl.Resources>
  37. <UserControl.DataContext>
  38. <vm:RecipeReceiveViewModel />
  39. </UserControl.DataContext>
  40. <Grid>
  41. <Grid.RowDefinitions>
  42. <RowDefinition Height="50"/>
  43. <RowDefinition />
  44. </Grid.RowDefinitions>
  45. <StackPanel HorizontalAlignment="Right" Orientation="Horizontal">
  46. <pry:IcoButton
  47. Width="140"
  48. Margin="10"
  49. HorizontalAlignment="Left"
  50. Command="{Binding NewRecipe}"
  51. Content="自定义配方"
  52. FontSize="16"
  53. Foreground="Aqua"
  54. IcoText="&#xe626;"
  55. Style="{StaticResource IcoButtonStyle}" />
  56. <pry:IcoButton
  57. Width="140"
  58. Margin="10"
  59. HorizontalAlignment="Left"
  60. Command="{Binding NewSimulateRecipe}"
  61. Content="新建模拟配方"
  62. FontSize="16"
  63. Foreground="Aqua"
  64. IcoText="&#xe626;"
  65. Style="{StaticResource IcoButtonStyle}" />
  66. <pry:IcoButton
  67. Grid.Column="3"
  68. Width="140"
  69. Margin="10"
  70. HorizontalAlignment="Left"
  71. Command="{Binding ClearAllRecipe}"
  72. Content="清除所有配方"
  73. FontSize="16"
  74. Foreground="Aqua"
  75. IcoText="&#xe635;"
  76. IsEnabled="True"
  77. Style="{StaticResource IcoButtonStyle}" />
  78. </StackPanel>
  79. <ScrollViewer Grid.Row="1">
  80. <ListView
  81. Margin="5"
  82. VerticalAlignment="Top"
  83. Background="Transparent"
  84. BorderThickness="0"
  85. ItemsSource="{Binding Recipes}"
  86. ScrollViewer.HorizontalScrollBarVisibility="Disabled">
  87. <ListView.ItemsPanel>
  88. <ItemsPanelTemplate>
  89. <UniformGrid
  90. HorizontalAlignment="Left"
  91. VerticalAlignment="Top"
  92. Columns="8" />
  93. </ItemsPanelTemplate>
  94. </ListView.ItemsPanel>
  95. <ListView.ItemTemplate>
  96. <DataTemplate>
  97. <Border Margin="5" Background="LightSkyBlue">
  98. <Grid>
  99. <Grid.RowDefinitions>
  100. <RowDefinition />
  101. <RowDefinition Height="0.25*" />
  102. <RowDefinition Height="0.2*" />
  103. </Grid.RowDefinitions>
  104. <Image Source="/BPASmartClient.CustomResource;component/Image/AGV/炒锅.png" />
  105. <WrapPanel Grid.Row="1">
  106. <TextBlock
  107. Margin="2,0,0,0"
  108. Foreground="#dd000000"
  109. Text="名称:" />
  110. <TextBlock
  111. Margin="2,0,0,0"
  112. Foreground="#dd000000"
  113. Text="{Binding RecipeName}" />
  114. <TextBlock
  115. Margin="5,0,0,0"
  116. Foreground="#dd000000"
  117. Text="编号:" />
  118. <TextBlock
  119. Margin="2,0,0,0"
  120. Foreground="#dd000000"
  121. Text="{Binding RecipeCode}" />
  122. <TextBlock
  123. Margin="5,0,0,0"
  124. Foreground="#dd000000"
  125. Text="托盘号:" />
  126. <TextBlock
  127. Margin="2,0,0,0"
  128. Foreground="#dd000000"
  129. Text="{Binding TrayCode}" />
  130. </WrapPanel>
  131. <Grid
  132. Name="gr"
  133. Grid.Row="2"
  134. Height="30">
  135. <Grid.ColumnDefinitions>
  136. <ColumnDefinition />
  137. </Grid.ColumnDefinitions>
  138. <pry:IcoButton
  139. Grid.Column="0"
  140. Width="{Binding ElementName=gr, Path=ActualWidth}"
  141. Height="{Binding ElementName=gr, Path=ActualHeight}"
  142. HorizontalAlignment="Center"
  143. VerticalAlignment="Center"
  144. BorderThickness="0"
  145. Command="{Binding DataContext.DetailsCommand, RelativeSource={RelativeSource AncestorType=ListView, Mode=FindAncestor}}"
  146. CommandParameter="{Binding RecipeCode}"
  147. Content="详情"
  148. EnterBackground="#FF2AB2E7"
  149. Foreground="#dd000000"
  150. IcoText="&#xe636;"
  151. Style="{StaticResource IcoButtonStyle}" />
  152. </Grid>
  153. </Grid>
  154. </Border>
  155. </DataTemplate>
  156. </ListView.ItemTemplate>
  157. </ListView>
  158. </ScrollViewer>
  159. </Grid>
  160. </UserControl>