59 lines
2.6 KiB
Plaintext
59 lines
2.6 KiB
Plaintext
![]() |
<Window xmlns="https://github.com/avaloniaui"
|
|||
|
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"
|
|||
|
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
|
|||
|
x:Class="demo0411.ProductList"
|
|||
|
x:CompileBindings="False"
|
|||
|
Icon="/Assets/Мастер пол.ico"
|
|||
|
Title="ProductList">
|
|||
|
<StackPanel>
|
|||
|
<TextBlock FontFamily="Segoe UI" Text="Список продуктов" HorizontalAlignment="Center"/>
|
|||
|
<ListBox Background="#F4E8D3" SelectionMode="Single" Height="400" Name="ListPartnerProduct" Margin="5">
|
|||
|
<ListBox.ItemTemplate>
|
|||
|
<DataTemplate>
|
|||
|
<Border Tag="{Binding Id}" DoubleTapped="Border_DoubleTapped" Background="#F4E8D3" BorderBrush="Black" BorderThickness="2">
|
|||
|
<StackPanel>
|
|||
|
<TextBlock FontFamily="Segoe UI" Text="{Binding Id}" HorizontalAlignment="Right"/>
|
|||
|
<TextBlock FontFamily="Segoe UI" Text="Название продукта"/>
|
|||
|
<TextBlock FontFamily="Segoe UI" Text="{Binding Name}"/>
|
|||
|
<TextBlock FontFamily="Segoe UI" Text="Тип продукта"/>
|
|||
|
<TextBlock FontFamily="Segoe UI" Text="{Binding Type.Name}"/>
|
|||
|
<TextBlock FontFamily="Segoe UI" Text="Коэфф продукта"/>
|
|||
|
<TextBlock FontFamily="Segoe UI" Text="{Binding Type.Coefficient}"/>
|
|||
|
<DockPanel>
|
|||
|
<TextBlock Margin="20 40" FontFamily="Segoe UI" Text="Есть у соедующих партнеров:"/>
|
|||
|
<ListBox Background="#F4E8D3" ItemsSource="{Binding PartnerProducts}" Height="100" ScrollViewer.HorizontalScrollBarVisibility="Visible">
|
|||
|
<ListBox.ItemsPanel>
|
|||
|
<ItemsPanelTemplate>
|
|||
|
<VirtualizingStackPanel Orientation="Horizontal" />
|
|||
|
</ItemsPanelTemplate>
|
|||
|
</ListBox.ItemsPanel>
|
|||
|
<ListBox.ItemTemplate>
|
|||
|
<DataTemplate>
|
|||
|
<Border CornerRadius="10">
|
|||
|
<TextBlock Margin="5" HorizontalAlignment="Center" VerticalAlignment="Center" Text="{Binding Partner.Name}" />
|
|||
|
</Border>
|
|||
|
</DataTemplate>
|
|||
|
</ListBox.ItemTemplate>
|
|||
|
</ListBox>
|
|||
|
</DockPanel>
|
|||
|
</StackPanel>
|
|||
|
</Border>
|
|||
|
</DataTemplate>
|
|||
|
</ListBox.ItemTemplate>
|
|||
|
</ListBox>
|
|||
|
<DockPanel>
|
|||
|
<Button Background="#67BA80" Content="Добавить товар" Click="Button_Click"/>
|
|||
|
<Button Background="#67BA80" Content="История реализации товаров" Click="Button_Click_1"/>
|
|||
|
|
|||
|
</DockPanel>
|
|||
|
<StackPanel>
|
|||
|
<Button Margin="20 40" Background="#67BA80" Content="Назад" Click="Button_Click_2"/>
|
|||
|
</StackPanel>
|
|||
|
|
|||
|
</StackPanel>
|
|||
|
|
|||
|
|
|||
|
</Window>
|