|
| 1 | +<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui" |
| 2 | + xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" |
| 3 | + xmlns:dxg="clr-namespace:DevExpress.Maui.DataGrid;assembly=DevExpress.Maui.DataGrid" |
| 4 | + xmlns:dxe="clr-namespace:DevExpress.Maui.Editors;assembly=DevExpress.Maui.Editors" |
| 5 | + xmlns:ios="clr-namespace:Microsoft.Maui.Controls.PlatformConfiguration.iOSSpecific;assembly=Microsoft.Maui.Controls" |
| 6 | + ios:Page.UseSafeArea="False" |
| 7 | + x:Class="MauiDataGridView_GetFromASPServer.MainPage"> |
| 8 | + <Grid> |
| 9 | + <dxg:DataGridView x:Name="datagrid" |
| 10 | + EditorShowMode="Never" IsReadOnly="False" VerticalLineThickness="1" ShowGroupedColumns="True"> |
| 11 | + <dxg:DataGridView.CellAppearance> |
| 12 | + <dxg:CellAppearance BorderColor="Transparent" HorizontalLineThickness="0"/> |
| 13 | + </dxg:DataGridView.CellAppearance> |
| 14 | + <dxg:DataGridView.GroupRowAppearance> |
| 15 | + <dxg:GroupRowAppearance BackgroundColor="Transparent"/> |
| 16 | + </dxg:DataGridView.GroupRowAppearance> |
| 17 | + <dxg:DataGridView.Columns> |
| 18 | + <dxg:TemplateColumn MinWidth="310" Caption="Customers" FieldName="Name" IsGrouped="true" GroupInterval="Alphabetical" SortOrder="Ascending"> |
| 19 | + <dxg:TemplateColumn.DisplayTemplate> |
| 20 | + <DataTemplate> |
| 21 | + <Grid VerticalOptions="Center" Padding="15, 5, 0, 10" RowDefinitions="*" ColumnDefinitions="Auto, 3*, *"> |
| 22 | + <Border |
| 23 | + x:Name="photoContainer" |
| 24 | + WidthRequest="60" |
| 25 | + HeightRequest="60" |
| 26 | + Margin="0,0,15,0" |
| 27 | + Grid.Column="0" |
| 28 | + VerticalOptions="Center"> |
| 29 | + <Border.Clip> |
| 30 | + <EllipseGeometry RadiusX="30" RadiusY="30" Center="30,30"/> |
| 31 | + </Border.Clip> |
| 32 | + <Image Source="{Binding Item.Image}" Grid.Column="0" WidthRequest="92" HeightRequest="92" Margin="0,0,5,0" HorizontalOptions="Center" VerticalOptions="Start"/> |
| 33 | + </Border> |
| 34 | + <VerticalStackLayout Grid.Row="0" Grid.Column="1" Padding="0" Margin="0" Opacity="0.7"> |
| 35 | + <Label Text="{Binding Item.Name}" FontSize="16" FontAttributes="Bold"/> |
| 36 | + <HorizontalStackLayout Margin="0,4,0,0" > |
| 37 | + <Label Text="📞" Padding="0,0,5,0" FontSize="10" VerticalTextAlignment="Center" /> |
| 38 | + <Label Text="{Binding Item.Phone}" FontSize="14"/> |
| 39 | + </HorizontalStackLayout> |
| 40 | + <HorizontalStackLayout> |
| 41 | + <Label Text="📆" Padding="0,0,5,0" FontSize="10" VerticalTextAlignment="Center" /> |
| 42 | + <Label Text="{Binding Item.BirthDate, StringFormat='{0:MMMM dd, yyyy}'}" FontSize="14" Margin="0,0,0,0"/> |
| 43 | + </HorizontalStackLayout> |
| 44 | + <HorizontalStackLayout> |
| 45 | + <Label Text="🏢" Padding="0,0,5,0" FontSize="10" VerticalTextAlignment="Center" /> |
| 46 | + <Label Text="{Binding Item.FavoriteStore}" FontSize="12" Margin="0,0,0,0"/> |
| 47 | + </HorizontalStackLayout> |
| 48 | + </VerticalStackLayout> |
| 49 | + </Grid> |
| 50 | + </DataTemplate> |
| 51 | + </dxg:TemplateColumn.DisplayTemplate> |
| 52 | + </dxg:TemplateColumn> |
| 53 | + </dxg:DataGridView.Columns> |
| 54 | + </dxg:DataGridView> |
| 55 | + </Grid> |
| 56 | + |
| 57 | + |
| 58 | +</ContentPage> |
0 commit comments