|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177 |
- <UserControl
- x:Class="BPASmartClient.SmallBatchingSystem.Views.SiloManagementView"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:con="clr-namespace:BPASmartClient.SmallBatchingSystem.Converter"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:local="clr-namespace:BPASmartClient.SmallBatchingSystem.Views"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:pry="clr-namespace:BPASmartClient.CustomResource.UserControls;assembly=BPASmartClient.CustomResource"
- xmlns:vm="clr-namespace:BPASmartClient.SmallBatchingSystem.ViewModels"
- d:DesignHeight="450"
- d:DesignWidth="800"
- mc:Ignorable="d">
-
- <UserControl.DataContext>
- <vm:SiloManagementViewModel />
- </UserControl.DataContext>
-
- <Grid Margin="10">
- <Grid.RowDefinitions>
- <RowDefinition Height="40" />
- <RowDefinition />
- </Grid.RowDefinitions>
-
- <StackPanel HorizontalAlignment="Right" Orientation="Horizontal">
- <Button
- Width="150"
- Height="40"
- Margin="10,0,10,0"
- Command="{Binding AddCommand}"
- Content="添加料仓"
- FontSize="20"
- Style="{StaticResource ImageButtonStyle}" />
- <Button
- Width="150"
- Height="40"
- Margin="10,0,10,0"
- Command="{Binding SaveCommand}"
- Content="保存参数"
- FontSize="20"
- Style="{StaticResource ImageButtonStyle}" />
- </StackPanel>
-
- <Grid Grid.Row="1">
- <ListView
- Margin="10"
- Background="Transparent"
- BorderBrush="#00BEFA"
- BorderThickness="0"
- ItemsSource="{Binding SiloInfoModels}"
- ScrollViewer.HorizontalScrollBarVisibility="Disabled">
- <ListView.ItemsPanel>
- <ItemsPanelTemplate>
- <WrapPanel Orientation="Horizontal" />
- </ItemsPanelTemplate>
- </ListView.ItemsPanel>
-
- <ListView.ItemTemplate>
- <DataTemplate>
- <Border
- Name="ShadowElement"
- Width="180"
- Height="150"
- Margin="10"
- VerticalAlignment="Top"
- BorderBrush="#00BEFA"
- BorderThickness="0"
- ClipToBounds="True"
- CornerRadius="0">
- <Border.Background>
- <ImageBrush ImageSource="/BPASmartClient.CustomResource;component/Image/蓝色背景.png" Stretch="Fill" />
- </Border.Background>
-
- <Grid Margin="20,0">
-
- <Grid.RowDefinitions>
- <RowDefinition />
- <RowDefinition />
- <RowDefinition />
- </Grid.RowDefinitions>
-
- <TextBlock
- Grid.Row="0"
- Grid.ColumnSpan="2"
- Margin="0,10,0,0"
- VerticalAlignment="Center"
- FontSize="20"
- Foreground="#00BEFA"
- Text="{Binding SiloName}" />
-
- <StackPanel
- Grid.Row="1"
- VerticalAlignment="Center"
- Orientation="Horizontal">
- <TextBlock
- Grid.Row="1"
- FontSize="14"
- Foreground="#aa00BEFA"
- Text="料仓位置:" />
- <TextBlock
- Grid.Row="1"
- FontSize="14"
- Foreground="#aa00BEFA"
- Text="{Binding SiloLoc}" />
- </StackPanel>
-
-
- <Grid
- Name="gr"
- Grid.Row="2"
- Height="30"
- Margin="0,0,0,10">
- <Grid.ColumnDefinitions>
- <ColumnDefinition />
- <ColumnDefinition />
- </Grid.ColumnDefinitions>
-
- <pry:IcoButton
- Width="{Binding ElementName=gr, Path=ActualWidth}"
- Height="{Binding ElementName=gr, Path=ActualHeight}"
- Margin="4,4,3,0"
- HorizontalAlignment="Center"
- VerticalAlignment="Center"
- Background="#11F53F62"
- BorderThickness="0"
- Command="{Binding DataContext.RemoveCommand, RelativeSource={RelativeSource AncestorType=ListBox, Mode=FindAncestor}}"
- CommandParameter="{Binding SiloName}"
- Content="删除"
- EnterBackground="#22F53F62"
- FontStyle="Normal"
- Foreground="#FFF53F62"
- IcoText=""
- Style="{StaticResource IcoButtonStyle}" />
-
- <pry:IcoButton
- Grid.Column="1"
- Width="{Binding ElementName=gr, Path=ActualWidth}"
- Height="{Binding ElementName=gr, Path=ActualHeight}"
- Margin="3,4,4,0"
- HorizontalAlignment="Center"
- VerticalAlignment="Center"
- Background="#112AB2E7"
- BorderThickness="0"
- Command="{Binding DataContext.DetailsCommand, RelativeSource={RelativeSource AncestorType=ListBox, Mode=FindAncestor}}"
- CommandParameter="{Binding SiloName}"
- Content="编辑"
- EnterBackground="#222AB2E7"
- Foreground="#FF2AB2E7"
- IcoText=""
- Style="{StaticResource IcoButtonStyle}" />
-
- </Grid>
-
- <!--<Button
- Grid.Row="2"
- Width="130"
- Height="30"
- Margin="0,0,0,0"
- VerticalAlignment="Top"
- Command="{Binding DataContext.ChangeNameCommand, RelativeSource={RelativeSource AncestorType=ListView, Mode=FindAncestor}}"
- CommandParameter="{Binding IpAddress}"
- Content="修改原料名称"
- FontSize="16"
- IsEnabled="{Binding IsEnable}"
- Style="{StaticResource ImageButtonStyle}" />-->
-
- </Grid>
- </Border>
-
- </DataTemplate>
- </ListView.ItemTemplate>
- </ListView>
- </Grid>
-
-
- </Grid>
- </UserControl>
|