demka/demofinish/MainWindow.axaml

78 lines
4.2 KiB
Plaintext
Raw Normal View History

2024-12-26 13:15:57 +00:00
<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="demofinish.MainWindow"
2025-03-25 18:36:42 +00:00
x:CompileBindings="False"
2024-12-26 13:15:57 +00:00
Title="demofinish">
2025-03-25 18:36:42 +00:00
<DockPanel>
<StackPanel DockPanel.Dock="Top" Margin="10" HorizontalAlignment="Center" Orientation="Horizontal">
2025-04-02 10:09:44 +00:00
<StackPanel Orientation="Vertical" Margin="5">
<TextBlock Text=""/>
2025-04-02 11:50:36 +00:00
<AutoCompleteBox x:Name="SearchBox" Watermark="Поиск" FilterMode="StartsWith" HorizontalAlignment="Center" Margin="5" Width="200" SelectionChanged="SearchBox_SelectionChanged"/>
2025-04-02 10:09:44 +00:00
</StackPanel>
2025-03-31 18:03:22 +00:00
<StackPanel Orientation="Vertical" Margin="5">
<TextBlock Text="Тип агента"/>
<ComboBox x:Name="TypeAgentCombobox" Margin="5" Width="200">
2025-03-26 09:39:33 +00:00
<ComboBox.ItemTemplate>
<DataTemplate>
<TextBlock Text="{Binding}"/>
</DataTemplate>
</ComboBox.ItemTemplate>
</ComboBox>
2025-03-31 18:03:22 +00:00
</StackPanel>
2025-03-26 09:39:33 +00:00
2025-03-31 18:03:22 +00:00
<StackPanel Orientation="Vertical" Margin="5">
<TextBlock Text="Сортировка приоритета"/>
<ComboBox MaxDropDownHeight="100" Width="200" Margin="5" x:Name="PriorityCombobox">
<ComboBoxItem>по убыванию</ComboBoxItem>
<ComboBoxItem>по возрастанию</ComboBoxItem>
2025-03-25 18:36:42 +00:00
</ComboBox>
2025-03-31 18:03:22 +00:00
</StackPanel>
<StackPanel Orientation="Vertical" Margin="5">
<TextBlock Text="Сортировка наименования"/>
<ComboBox MaxDropDownHeight="100" Width="200" Margin="5" x:Name="NameComboBox">
<ComboBoxItem>по убыванию</ComboBoxItem>
<ComboBoxItem>по возрастанию</ComboBoxItem>
</ComboBox>
</StackPanel>
<StackPanel Orientation="Vertical" Margin="5">
<TextBlock Text="Сортировка по скидке"/>
<ComboBox MaxDropDownHeight="100" Width="200" Margin="5" x:Name="SaleCombobox">
<ComboBoxItem>по убыванию</ComboBoxItem>
<ComboBoxItem>по возрастанию</ComboBoxItem>
</ComboBox>
</StackPanel>
2025-03-25 18:36:42 +00:00
</StackPanel>
2025-04-02 10:09:44 +00:00
<ListBox x:Name="AgentListBox" SelectionChanged="AgentListBox_OnSelectionChanged">
2025-03-25 18:36:42 +00:00
<ListBox.ItemsPanel>
<ItemsPanelTemplate>
<UniformGrid Columns="3"/>
</ItemsPanelTemplate>
</ListBox.ItemsPanel>
<ListBox.ItemTemplate>
<DataTemplate>
<Border BorderThickness="1" Margin="5">
<StackPanel HorizontalAlignment="Center" Spacing="5">
2025-03-26 09:39:33 +00:00
<Image HorizontalAlignment="Center" Width="100" Height="100" Source="{Binding LogoImage}" Margin="5"/>
2025-03-31 18:03:22 +00:00
<TextBlock Text="{Binding Title, StringFormat='Наименование: {0}'}"/>
<TextBlock Text="{Binding Phone, StringFormat='Телефон: {0}'}"/>
<TextBlock Text="{Binding Agenttypeid, StringFormat='Тип агента: {0}'}"/>
2025-03-25 18:36:42 +00:00
</StackPanel>
</Border>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
2025-04-01 11:42:23 +00:00
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Margin="10">
2025-03-26 09:39:33 +00:00
<Button Content="Назад" Margin="5" Click="PrevPage_Click"/>
<TextBlock Text="{Binding currentPage}" VerticalAlignment="Center" Margin="5"/>
<TextBlock Text="{Binding pageCount}" VerticalAlignment="Center" Margin="5"/>
<Button Content="Вперед" Margin="5" Click="NextPage_Click"/>
2025-04-01 11:42:23 +00:00
<Button Content="Добавить агента" Margin="5" Click="AddNew_Agent" />
2025-03-26 09:39:33 +00:00
</StackPanel>
2025-03-25 18:36:42 +00:00
</DockPanel>
</Window>