123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116 |
- <Page x:Class="school.pageServicesList"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:local="clr-namespace:school"
- mc:Ignorable="d"
- d:DesignHeight="450" d:DesignWidth="800"
- Title="pageServicesList">
- <Page.Resources>
- <BitmapImage x:Key="_noPhoto" UriSource="/Resource/noPhoto.png"/>
- </Page.Resources>
- <Grid Margin="7">
- <Grid.RowDefinitions>
- <RowDefinition Height="0.1*" MinHeight="50"></RowDefinition>
- <RowDefinition Height="*"></RowDefinition>
- </Grid.RowDefinitions>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="Auto"></ColumnDefinition>
- <ColumnDefinition Width="*"></ColumnDefinition>
- </Grid.ColumnDefinitions>
- <Grid Grid.Row="0" Margin="7" Grid.Column="0" Grid.ColumnSpan="2">
- <Grid.ColumnDefinitions>
- <ColumnDefinition></ColumnDefinition>
- <ColumnDefinition Width="0.3*"></ColumnDefinition>
- </Grid.ColumnDefinitions>
- <StackPanel HorizontalAlignment="Left" Orientation="Horizontal">
- <Button Name="BtnSort" Click="BtnSortClick" Style="{StaticResource usuallyButtonFill}" Width="150" >Сортировать</Button>
- <Button Name="BtnAdd" Click="BtnAddClick" Visibility="Collapsed" Style="{StaticResource usuallyButtonFill}" Width="150" Margin="10 0">Добавить</Button>
- <Button Name="BtnRead" Click="BtnReadClick" Visibility="Collapsed" Style="{StaticResource usuallyButtonFill}" Width="150">Ближайшие записи</Button>
- </StackPanel>
- <Viewbox Grid.Column="1">
- <Button Name="BtnAdminAuthorizstion" Click="BtnAdminAuthorizstionClick" Content="Войти" Style="{StaticResource usuallyButton}"/>
- </Viewbox>
- </Grid>
- <Grid Name="GSort" Grid.Row="1" Grid.Column="0" Visibility="Collapsed">
- <ScrollViewer HorizontalScrollBarVisibility="Disabled" VerticalScrollBarVisibility="Auto">
- <Grid Margin="5">
- <Grid.RowDefinitions>
- <RowDefinition></RowDefinition>
- <RowDefinition Height="Auto"></RowDefinition>
- </Grid.RowDefinitions>
- <StackPanel Grid.Row="0">
- <GroupBox Header="Сортировать по стоимости" Style="{StaticResource usuallyGroupBox}">
- <StackPanel>
- <RadioButton Name="RBSalaryUp" Style="{StaticResource usuallyRadioButton}" Checked="SortChecked">По возрастанию</RadioButton>
- <RadioButton Name="RBSalaryDown" Style="{StaticResource usuallyRadioButton}" Checked="SortChecked">По убыванию</RadioButton>
- </StackPanel>
- </GroupBox>
- <GroupBox Header="Сортировать по размеру скидки" Style="{StaticResource usuallyGroupBox}">
- <ComboBox Name="CBDiscount" SelectionChanged="CBDiscountSelectionChanged" Style="{StaticResource usuallyComboBox}"></ComboBox>
- </GroupBox>
- <GroupBox Header="Поиск по названию" Style="{StaticResource usuallyGroupBox}">
- <TextBox Name="TBSearchName" TextChanged="TBSearchTextChanged" Tag="Введите.." Style="{StaticResource usuallyTextBloxSearch}"></TextBox>
- </GroupBox>
- <GroupBox Header="Поиск по описанию" Style="{StaticResource usuallyGroupBox}">
- <TextBox Name="TBSearchDiscription" TextChanged="TBSearchTextChanged" Tag="Введите.." Style="{StaticResource usuallyTextBloxSearch}"></TextBox>
- </GroupBox>
- </StackPanel>
- <Grid Grid.Row="1">
- <Button Name="BtnNoSort" Click="BtnNoSortClick" Style="{StaticResource usuallyButtonNoFill}" HorizontalAlignment="Left">Сбросить фильтры</Button>
- <TextBlock Name="TBCountRecord" Style="{StaticResource usuallyTextBlock}" HorizontalAlignment="Right" VerticalAlignment="Bottom">Количество</TextBlock>
- </Grid>
- </Grid>
- </ScrollViewer>
- </Grid>
- <Grid Grid.Row="1" Grid.Column="1">
- <ListView Name="LVServiseList" BorderBrush="White" ScrollViewer.HorizontalScrollBarVisibility="Disabled" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch">
- <ListView.ItemTemplate>
- <DataTemplate>
- <Border BorderBrush="LightSlateGray" BorderThickness="1" Background="{Binding colorDiscount}" CornerRadius="5">
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="120"></ColumnDefinition>
- <ColumnDefinition Width="*"></ColumnDefinition>
- </Grid.ColumnDefinitions>
- <Grid Grid.Column="0" Margin="5">
- <Image Name="imgServise" Source="{Binding Path=imgServise, TargetNullValue={StaticResource _noPhoto}}" Stretch="Uniform"/>
- </Grid>
- <StackPanel Grid.Column="1" Margin="5">
- <StackPanel Margin="0 0 0 15">
- <TextBlock Name="TBNameService" Text="{Binding Title}" TextWrapping="Wrap" Style="{StaticResource usuallyTextBlock}"/>
- <StackPanel Orientation="Horizontal">
- <TextBlock Text="{Binding oldPrice}" TextDecorations="Strikethrough" Visibility="{Binding discountVisible}" Style="{StaticResource usuallyTextBlock}"/>
- <TextBlock Name="TBPriceService" Text="{Binding price}" TextWrapping="Wrap" Style="{StaticResource usuallyTextBlock}"/>
- </StackPanel>
- <TextBlock Name="TBSaleService" Text="{Binding sale}" TextWrapping="Wrap" Style="{StaticResource usuallyTextBlock}"/>
- </StackPanel>
- <Grid>
- <StackPanel Orientation="Horizontal">
- <Button Uid="{Binding ID}" Name="BtnEdit" Click="BtnEditClick" Content="Редактировать" Style="{StaticResource usuallyButton}" Margin="10 0" Visibility="{Binding btnAdminVisible}"/>
- <Button Uid="{Binding ID}" Name="BtnDelete" Click="BtnDeleteClick" Content="Удалить" Style="{StaticResource usuallyButton}" Margin="10 0" Visibility="{Binding btnAdminVisible}"/>
- </StackPanel>
- <Button Uid="{Binding ID}" Name="BtnWrite" Click="BtnWriteClick" Content="{Binding nameBtn}" Style="{StaticResource usuallyButton}" Margin="10 0" HorizontalAlignment="Right"/>
- </Grid>
- </StackPanel>
- </Grid>
- </Border>
- </DataTemplate>
- </ListView.ItemTemplate>
- </ListView>
- <TextBlock Name="TBNoSevise" Style="{StaticResource usuallyTextBlockHeader}" FontSize="30">Нет подходящих услуг</TextBlock>
- </Grid>
- </Grid>
- </Page>
|