|
@@ -24,6 +24,9 @@
|
|
|
<DataTemplate x:Key="EditingDateTemplate">
|
|
|
<DatePicker SelectedDate="{Binding Birthday, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" />
|
|
|
</DataTemplate>
|
|
|
+
|
|
|
+ <!--BTV-->
|
|
|
+ <BooleanToVisibilityConverter x:Key="BTV"/>
|
|
|
</Page.Resources>
|
|
|
|
|
|
<StackPanel>
|
|
@@ -44,7 +47,9 @@
|
|
|
<MenuItem Header="Отчет"></MenuItem>
|
|
|
</Menu>
|
|
|
|
|
|
- <ToolBar>
|
|
|
+ <Label HorizontalAlignment="Center" FontSize="24">Список сотрудников</Label>
|
|
|
+
|
|
|
+ <ToolBar Margin="8">
|
|
|
<Button Name="Undo" Command="{Binding UndoCommand}" ToolTip="Отменить редактирование/создание">
|
|
|
<Image Width="32" Height="32" Source="/Images/undo.png" />
|
|
|
</Button>
|
|
@@ -65,18 +70,80 @@
|
|
|
</Button>
|
|
|
</ToolBar>
|
|
|
|
|
|
- <Label>Список сотрудников</Label>
|
|
|
-
|
|
|
<!--Main-->
|
|
|
- <Grid>
|
|
|
- <Grid.ColumnDefinitions>
|
|
|
- <ColumnDefinition Width="*"/>
|
|
|
- <ColumnDefinition Width="*"/>
|
|
|
- </Grid.ColumnDefinitions>
|
|
|
+ <StackPanel>
|
|
|
+
|
|
|
+ <!--Поле поиска-->
|
|
|
+ <Grid
|
|
|
+ Visibility="{Binding FilterActive,Converter={StaticResource BTV}}"
|
|
|
+ Grid.Column="1"
|
|
|
+ Background="#ddd"
|
|
|
+ Margin="8">
|
|
|
+ <Grid.ColumnDefinitions>
|
|
|
+ <ColumnDefinition Width="64"/>
|
|
|
+ <ColumnDefinition Width="*"/>
|
|
|
+ <ColumnDefinition Width="32"/>
|
|
|
+ </Grid.ColumnDefinitions>
|
|
|
+ <Grid.RowDefinitions>
|
|
|
+ <RowDefinition Height="16"/>
|
|
|
+ <RowDefinition Height="32"/>
|
|
|
+ <RowDefinition Height="32"/>
|
|
|
+ </Grid.RowDefinitions>
|
|
|
+
|
|
|
+ <Label
|
|
|
+ Content="Поиск"
|
|
|
+ HorizontalAlignment="Center"
|
|
|
+ Grid.Column="0"
|
|
|
+ Grid.ColumnSpan="3"
|
|
|
+ Grid.Row="0"/>
|
|
|
+
|
|
|
+ <Label
|
|
|
+ Content="Фамилия"
|
|
|
+ HorizontalAlignment="Right"
|
|
|
+ VerticalAlignment="Center"
|
|
|
+ Grid.Column="0"
|
|
|
+ Grid.Row="1"/>
|
|
|
+ <TextBox
|
|
|
+ VerticalContentAlignment="Center"
|
|
|
+ Grid.Column="1"
|
|
|
+ Margin="4"
|
|
|
+ Grid.Row="1"
|
|
|
+ Text="{Binding FilterSurname,UpdateSourceTrigger=PropertyChanged}"/>
|
|
|
+ <Button
|
|
|
+ Grid.Column="2"
|
|
|
+ Grid.Row="1"
|
|
|
+ Margin="4"
|
|
|
+ ToolTip="Поиск по фамилии">
|
|
|
+ <Image Source="/Images/search.png" />
|
|
|
+ </Button>
|
|
|
+
|
|
|
+ <Label
|
|
|
+ Content="Должность"
|
|
|
+ HorizontalAlignment="Right"
|
|
|
+ VerticalAlignment="Center"
|
|
|
+ Grid.Column="0"
|
|
|
+ Grid.Row="2"/>
|
|
|
+ <ComboBox
|
|
|
+ VerticalContentAlignment="Center"
|
|
|
+ Margin="4"
|
|
|
+ Grid.Column="1"
|
|
|
+ Grid.Row="2"
|
|
|
+ ItemsSource="{Binding DataContext.AllTitles,Source={x:Reference ProxyElement}}"
|
|
|
+ DisplayMemberPath="Name"
|
|
|
+ SelectedItem="{Binding FilterTitle, UpdateSourceTrigger=PropertyChanged}"/>
|
|
|
+ <Button
|
|
|
+ Margin="4"
|
|
|
+ Grid.Column="2"
|
|
|
+ Grid.Row="2"
|
|
|
+ ToolTip="Поиск по должности">
|
|
|
+ <Image Source="/Images/search.png" />
|
|
|
+ </Button>
|
|
|
+ </Grid>
|
|
|
+ <!--/Поле поиска-->
|
|
|
|
|
|
<!--Сетка редактирования-->
|
|
|
<DataGrid
|
|
|
- Margin="4,0"
|
|
|
+ Margin="8"
|
|
|
Grid.Column="0"
|
|
|
AutoGenerateColumns="False"
|
|
|
ItemsSource="{Binding Employees}"
|
|
@@ -152,72 +219,7 @@
|
|
|
</DataGrid.Columns>
|
|
|
</DataGrid>
|
|
|
<!--/Сетка редактирования-->
|
|
|
-
|
|
|
- <!--Поле поиска-->
|
|
|
- <Grid Grid.Column="1" Background="#ddd" Margin="4,0">
|
|
|
- <Grid.ColumnDefinitions>
|
|
|
- <ColumnDefinition Width="64"/>
|
|
|
- <ColumnDefinition Width="*"/>
|
|
|
- <ColumnDefinition Width="32"/>
|
|
|
- </Grid.ColumnDefinitions>
|
|
|
- <Grid.RowDefinitions>
|
|
|
- <RowDefinition Height="16"/>
|
|
|
- <RowDefinition Height="32"/>
|
|
|
- <RowDefinition Height="32"/>
|
|
|
- </Grid.RowDefinitions>
|
|
|
-
|
|
|
- <Label
|
|
|
- Content="Поиск"
|
|
|
- HorizontalAlignment="Center"
|
|
|
- Grid.Column="0"
|
|
|
- Grid.ColumnSpan="3"
|
|
|
- Grid.Row="0"/>
|
|
|
-
|
|
|
- <Label
|
|
|
- Content="Фамилия"
|
|
|
- HorizontalAlignment="Right"
|
|
|
- VerticalAlignment="Center"
|
|
|
- Grid.Column="0"
|
|
|
- Grid.Row="1"/>
|
|
|
- <TextBox
|
|
|
- VerticalContentAlignment="Center"
|
|
|
- Grid.Column="1"
|
|
|
- Margin="4"
|
|
|
- Grid.Row="1"
|
|
|
- Text="{Binding FilterSurname,UpdateSourceTrigger=PropertyChanged}"/>
|
|
|
- <Button
|
|
|
- Grid.Column="2"
|
|
|
- Grid.Row="1"
|
|
|
- Margin="4"
|
|
|
- ToolTip="Поиск по фамилии">
|
|
|
- <Image Source="/Images/search.png" />
|
|
|
- </Button>
|
|
|
-
|
|
|
- <Label
|
|
|
- Content="Должность"
|
|
|
- HorizontalAlignment="Right"
|
|
|
- VerticalAlignment="Center"
|
|
|
- Grid.Column="0"
|
|
|
- Grid.Row="2"/>
|
|
|
- <ComboBox
|
|
|
- VerticalContentAlignment="Center"
|
|
|
- Margin="4"
|
|
|
- Grid.Column="1"
|
|
|
- Grid.Row="2"
|
|
|
- ItemsSource="{Binding DataContext.AllTitles,Source={x:Reference ProxyElement}}"
|
|
|
- DisplayMemberPath="Name"
|
|
|
- SelectedItem="{Binding FilterTitle, UpdateSourceTrigger=PropertyChanged}"/>
|
|
|
- <Button
|
|
|
- Margin="4"
|
|
|
- Grid.Column="2"
|
|
|
- Grid.Row="2"
|
|
|
- ToolTip="Поиск по должности">
|
|
|
- <Image Source="/Images/search.png" />
|
|
|
- </Button>
|
|
|
-
|
|
|
- </Grid>
|
|
|
- <!--/Поле поиска-->
|
|
|
- </Grid>
|
|
|
+ </StackPanel>
|
|
|
<!--/Main-->
|
|
|
</StackPanel>
|
|
|
</Page>
|