123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162 |
- <Window x:Class="wpf_connection3.MainWindow"
- 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:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:local="clr-namespace:wpf_connection3"
- mc:Ignorable="d"
- Title="MainWindow" Height="450" Width="800">
- <Grid ShowGridLines="True">
- <Grid.RowDefinitions>
- <RowDefinition Height="auto"/>
- <RowDefinition />
- <RowDefinition Height="50"/>
- </Grid.RowDefinitions>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="200"/>
- <ColumnDefinition/>
- </Grid.ColumnDefinitions>
- <ListBox
- Grid.Row="1"
- Grid.Column="1"
- Background="White"
- ItemsSource="{Binding productList}"
- ScrollViewer.HorizontalScrollBarVisibility="Disabled" Margin="3,3,0,0" RenderTransformOrigin="0.5,0.5">
- <ListBox.ItemContainerStyle>
- <Style
- TargetType="ListBoxItem">
- <Setter
- Property="HorizontalContentAlignment"
- Value="Stretch" />
- </Style>
- </ListBox.ItemContainerStyle>
- <ListBox.ItemTemplate>
- <DataTemplate>
- <Border
- BorderThickness="1"
- BorderBrush="Black"
- CornerRadius="5">
- <Grid
- Margin="10"
- HorizontalAlignment="Stretch">
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="64"/>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="auto"/>
- </Grid.ColumnDefinitions>
- <Image
- Width="64"
- Height="64"
- Source="{Binding ImageBitmap}" HorizontalAlignment="Center"/>
- <StackPanel
- Grid.Column="1"
- Margin="5"
- Orientation="Vertical">
- <TextBlock
- Text="{Binding Title}"/>
- <TextBlock
- Text="{Binding ArticleNumber}"/>
- </StackPanel>
- <TextBlock
- Grid.Column="2"
- Text="{Binding ProductTypeID}"/>
- </Grid>
- </Border>
- </DataTemplate>
- </ListBox.ItemTemplate>
- </ListBox>
- <WrapPanel
- Grid.Column="1"
- Orientation="Horizontal"
- ItemHeight="50">
- <ComboBox
- Width="150"
- x:Name="ProductTypeFilter"
- SelectedIndex="0"
- SelectionChanged="ProductTypeFilter_SelectionChanged"
- ItemsSource="{Binding productTypeList}"/>
- <ComboBox
- Name="SortTypeComboBox"
- SelectedIndex="0"
- VerticalContentAlignment="Center"
- MinWidth="200"
- SelectionChanged="SortTypeComboBox_SelectionChanged"
- ItemsSource="{Binding sortList}"/>
- <TextBox
- Width="200"
- VerticalAlignment="Center"
- x:Name="searchFilterTextBox"
- KeyUp="searchFilterTextBox_KeyUp"/>
- </WrapPanel>
- <ListBox
- x:Name="PageListListBox"
- ItemsSource="{Binding pageList}"
- Grid.Column="1"
- Grid.Row="2">
- <ListBox.ItemsPanel>
- <ItemsPanelTemplate>
- <WrapPanel
- HorizontalAlignment="Left" />
- </ItemsPanelTemplate>
- </ListBox.ItemsPanel>
- <ListBox.ItemTemplate>
- <DataTemplate>
- <TextBlock
- Margin="5"
- Text="{Binding}"
- PreviewMouseDown="TextBlock_PreviewMouseDown"/>
- </DataTemplate>
- </ListBox.ItemTemplate>
- </ListBox>
- <Image
- Grid.Row="0"
- Grid.RowSpan="2"
-
- Source="foto/1.jpg"
-
- />
- <StackPanel
- Grid.Row="2"
- Orientation="Vertical"
-
- VerticalAlignment="Bottom">
- <Button
- x:Name="ExitButton"
- Content="Выход"
- Click="ExitButton_Click"
- Height="54"/>
- </StackPanel>
- <WrapPanel
- Orientation="Horizontal"
- Grid.Column="1"
- MinHeight="50">
- </WrapPanel>
- </Grid>
- </Window>
|