You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
107 lines
4.9 KiB
107 lines
4.9 KiB
<?xml version="1.0" encoding="utf-8"?>
|
|
<ContentPage
|
|
xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
|
xmlns:youserbase="clr-namespace:YOUserbase"
|
|
x:DataType="youserbase:UserOverviewPage"
|
|
x:Class="YOUserbase.UserOverviewPage"
|
|
Title="User Overview">
|
|
<ScrollView>
|
|
<VerticalStackLayout
|
|
Spacing="25"
|
|
Padding="30,60"
|
|
VerticalOptions="Center">
|
|
|
|
<HorizontalStackLayout
|
|
Spacing="10">
|
|
<Button
|
|
x:Name="btnAdd"
|
|
Text="Add user"
|
|
SemanticProperties.Hint="Add a new user"
|
|
Clicked="OnAdd"
|
|
HorizontalOptions="Center" />
|
|
</HorizontalStackLayout>
|
|
<CollectionView
|
|
x:Name="users"
|
|
SelectionMode="None">
|
|
<CollectionView.ItemTemplate>
|
|
<DataTemplate>
|
|
<Grid
|
|
Padding="10">
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition
|
|
Height="*" />
|
|
</Grid.RowDefinitions>
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition
|
|
Width="30" />
|
|
<ColumnDefinition
|
|
Width="200" />
|
|
<ColumnDefinition
|
|
Width="200" />
|
|
<ColumnDefinition
|
|
Width="200" />
|
|
<ColumnDefinition
|
|
Width="*" />
|
|
<ColumnDefinition
|
|
Width="100" />
|
|
<ColumnDefinition
|
|
Width="100" />
|
|
</Grid.ColumnDefinitions>
|
|
<Label
|
|
Grid.Row="0"
|
|
Grid.Column="0"
|
|
Text="{Binding Id}"
|
|
VerticalOptions="CenterAndExpand"
|
|
HorizontalOptions="FillAndExpand" />
|
|
<Label
|
|
Grid.Row="0"
|
|
Grid.Column="1"
|
|
Text="{Binding Firstname}"
|
|
FontAttributes="Bold"
|
|
VerticalOptions="CenterAndExpand"
|
|
HorizontalOptions="FillAndExpand" />
|
|
<Label
|
|
Grid.Row="0"
|
|
Grid.Column="2"
|
|
Text="{Binding Lastname}"
|
|
FontAttributes="Bold"
|
|
VerticalOptions="CenterAndExpand"
|
|
HorizontalOptions="FillAndExpand" />
|
|
<Label
|
|
Grid.Row="0"
|
|
Grid.Column="3"
|
|
Text="{Binding BirthDate}"
|
|
FontAttributes="Bold"
|
|
VerticalOptions="CenterAndExpand"
|
|
HorizontalOptions="FillAndExpand" />
|
|
<Label
|
|
Grid.Row="0"
|
|
Grid.Column="4"
|
|
Text="{Binding Details}"
|
|
FontAttributes="Italic"
|
|
VerticalOptions="CenterAndExpand"
|
|
HorizontalOptions="FillAndExpand" />
|
|
<Button
|
|
Grid.Row="0"
|
|
Grid.Column="5"
|
|
x:Name="btnEditThis"
|
|
Text="Edit"
|
|
SemanticProperties.Hint="Edit this item"
|
|
Clicked="OnEditItem"
|
|
ClassId="{Binding Id}" />
|
|
<Button
|
|
Grid.Row="0"
|
|
Grid.Column="6"
|
|
x:Name="btnRemoveThis"
|
|
Text="Remove"
|
|
SemanticProperties.Hint="Deletes this item"
|
|
Clicked="OnDeleteItem"
|
|
ClassId="{Binding Id}" />
|
|
</Grid>
|
|
</DataTemplate>
|
|
</CollectionView.ItemTemplate>
|
|
</CollectionView>
|
|
</VerticalStackLayout>
|
|
</ScrollView>
|
|
</ContentPage> |