|
@@ -6,8 +6,8 @@
|
|
|
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
|
|
|
x:Class="AvaloniaApplicationTestNew.AdminPage"
|
|
|
x:DataType="vm:AdminPageViewModel">
|
|
|
-
|
|
|
- <Grid RowDefinitions="75,50,*" ColumnDefinitions="*">
|
|
|
+
|
|
|
+ <Grid RowDefinitions="75,50,*" ColumnDefinitions="*,*,*">
|
|
|
<StackPanel Orientation="Horizontal" Grid.Row="0" Margin="0 10 0 10">
|
|
|
<TextBlock Text="Поиск:"/>
|
|
|
<TextBox Text="{Binding FindText}" Watermark="Введите текст для поиска"/>
|
|
@@ -25,26 +25,29 @@
|
|
|
</ComboBox.ItemTemplate>
|
|
|
</ComboBox>
|
|
|
</StackPanel>
|
|
|
- <StackPanel Grid.Row="1" HorizontalAlignment="Center" Orientation="Horizontal">
|
|
|
+ <StackPanel Grid.Row="1" Grid.ColumnSpan="3" HorizontalAlignment="Center" Orientation="Horizontal">
|
|
|
<Button Content="Добавить пользователя" Command="{Binding AddUser}"/>
|
|
|
<Button Content="Выйти" Command="{Binding Exit}"/>
|
|
|
</StackPanel>
|
|
|
- <ListBox ItemsSource="{Binding LocalListusers}" Grid.Row="2" Background="Linen" Grid.Column="0">
|
|
|
+ <ListBox ItemsSource="{Binding LocalListusers}" Grid.Row="2" Background="Linen" Grid.ColumnSpan="3">
|
|
|
<ListBox.ItemTemplate>
|
|
|
<DataTemplate>
|
|
|
<StackPanel>
|
|
|
- <Grid ColumnDefinitions="*, 200">
|
|
|
- <StackPanel Grid.Column="0">
|
|
|
- <TextBlock Text="{Binding Name, StringFormat=Имя: {0}}"/>
|
|
|
- <TextBlock Text="{Binding BirthDate, StringFormat=Дата рождения: {0:dd/MM/yyyy}}"/>
|
|
|
- <TextBlock Text="{Binding IdGenderNavigation.Gender1, StringFormat=Пол: {0}}"/>
|
|
|
- <TextBlock Text="{Binding IdUserNavigation.IdRoleNavigation.RoleName, StringFormat=Роль в системе: {0}}"/>
|
|
|
- <Button Content="Изменить персональные данные пользователя" Command="{Binding $parent[UserControl].((vm:AdminPageViewModel)DataContext).InfoUsers}" CommandParameter="{Binding IdUser}"/>
|
|
|
- <Grid ColumnDefinitions="*, *" Grid.Column="1">
|
|
|
- <Image Grid.Column="1" Source="{Binding ConvertImage}" Width="150" Height="150"/>
|
|
|
- </Grid>
|
|
|
- </StackPanel>
|
|
|
- </Grid>
|
|
|
+ <StackPanel Grid.Column="1">
|
|
|
+ <TextBlock Text="{Binding Name, StringFormat=Имя: {0}}"/>
|
|
|
+ <TextBlock Text="{Binding BirthDate, StringFormat=Дата рождения: {0:dd/MM/yyyy}}"/>
|
|
|
+ <TextBlock Text="{Binding IdGenderNavigation.Gender1, StringFormat=Пол: {0}}"/>
|
|
|
+ <TextBlock Text="{Binding IdUserNavigation.IdRoleNavigation.RoleName, StringFormat=Роль в системе: {0}}"/>
|
|
|
+ <Button Content="Изменить персональные данные пользователя" Command="{Binding $parent[UserControl].((vm:AdminPageViewModel)DataContext).InfoUsers}" CommandParameter="{Binding IdUser}"/>
|
|
|
+ </StackPanel>
|
|
|
+ <ListBox ItemsSource="{Binding IdTraits}" Grid.Column="2" Grid.Row="2">
|
|
|
+ <ListBox.ItemTemplate>
|
|
|
+ <DataTemplate>
|
|
|
+ <TextBlock Text="{Binding Traitname}"/>
|
|
|
+ </DataTemplate>
|
|
|
+ </ListBox.ItemTemplate>
|
|
|
+ </ListBox>
|
|
|
+ <Image Source="{Binding ConvertImage}" Width="150" Height="150" Grid.Row="2" Grid.Column="3"/>
|
|
|
</StackPanel>
|
|
|
</DataTemplate>
|
|
|
</ListBox.ItemTemplate>
|