Adding a drag&drop on profil page. Binding of name surname etc... lost
continuous-integration/drone/push Build is passing Details

pull/65/head
Roxane ROSSETTO 2 years ago
parent 95f9642814
commit 765134f0ba

@ -61,7 +61,7 @@ namespace Views
/* - Comment(ctrl-k + ctrl-c)/Uncomment(ctrl-k + ctrl-u) to change page - */ /* - Comment(ctrl-k + ctrl-c)/Uncomment(ctrl-k + ctrl-u) to change page - */
UserAppTheme = AppTheme.Light; UserAppTheme = AppTheme.Light;
MainPage = new AddRecipe(); MainPage = new MyProfil();
//MainPage = new MyPosts(); //MainPage = new MyPosts();
} }

@ -1,73 +1,70 @@
<?xml version="1.0" encoding="utf-8" ?> <?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui" <ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:local="clr-namespace:Views" xmlns:local="clr-namespace:Views"
xmlns:model="clr-namespace:Model;assembly=Model" xmlns:model="clr-namespace:Model;assembly=Model"
x:Class="Views.MyProfil" x:Class="Views.MyProfil"
Title="MyProfil"> Title="MyProfil">
<ContentPage.Resources> <ContentPage.Resources>
<local:EnumToValuesConverter x:Key="musicTypeToValueConverter" <local:EnumToValuesConverter x:Key="musicTypeToValueConverter"
x:TypeArguments="model:Priority"/> x:TypeArguments="model:Priority"/>
</ContentPage.Resources> </ContentPage.Resources>
<local:ContainerBase <local:ContainerBase
IsNotConnected="False" IsNotConnected="False"
NeedReturn="True"> NeedReturn="True">
<local:ContainerBase.MyFlyoutContent> <local:ContainerBase.MyFlyoutContent>
<Grid RowDefinitions="250, *, *" VerticalOptions="Fill"> <Grid RowDefinitions="250, *, *" VerticalOptions="Fill">
<VerticalStackLayout Grid.Row="1"> <VerticalStackLayout Grid.Row="1">
<Button Text="Mes Recettes" ImageSource="person_default.png" Style="{StaticResource button1}" Grid.Row="1"/> <Button Text="Mes Recettes" ImageSource="person_default.png" Style="{StaticResource button1}" Grid.Row="1"/>
<Button Text="Ajouter Recette" ImageSource="settings_icon.png" Style="{StaticResource button1}" Grid.Row="2"/> <Button Text="Ajouter Recette" ImageSource="settings_icon.png" Style="{StaticResource button1}" Grid.Row="2"/>
</VerticalStackLayout> </VerticalStackLayout>
</Grid> </Grid>
</local:ContainerBase.MyFlyoutContent> </local:ContainerBase.MyFlyoutContent>
<local:ContainerBase.MyContent> <local:ContainerBase.MyContent>
<ScrollView> <ScrollView>
<StackLayout > <StackLayout >
<!--user's informations--> <!--user's informations-->
<Label Text="Mon profil" TextColor="{AppThemeBinding Light={StaticResource Black}, Dark={StaticResource Gray100}}" <Label Text="Mon profil" TextColor="{AppThemeBinding Light={StaticResource Black}, Dark={StaticResource Gray100}}"
FontAttributes="Bold" FontAttributes="Bold"
FontSize="24" Padding="15, 15, 20, 5"/> FontSize="24" Padding="15, 15, 20, 5"/>
<HorizontalStackLayout> <HorizontalStackLayout>
<VerticalStackLayout > <VerticalStackLayout >
<Label Text="Informations personnelles :" TextColor="{AppThemeBinding Light={StaticResource Black}, Dark={StaticResource Gray100}}" <Label Text="Informations personnelles :" TextColor="{AppThemeBinding Light={StaticResource Black}, Dark={StaticResource Gray100}}"
FontSize="20" Padding="15"/> FontSize="20" Padding="15"/>
<Label Text="Nom :" <Label Text="Nom :"
Padding="50,0,0,0" Padding="50,0,0,0"
FontSize="18"/> FontSize="18"/>
<Entry BackgroundColor="#D1E8E2" <Entry BackgroundColor="#D1E8E2"
Margin="50,10,0,20" Margin="50,10,0,20"
Text="{Binding CurrentUser.Name}"/> Text="{Binding CurrentUser.Name}"/>
<Label Text="Prénom :" <Label Text="Prénom :"
Padding="50,0,0,0" Padding="50,0,0,0"
FontSize="18"/> FontSize="18"/>
<Entry BackgroundColor="#D1E8E2" <Entry BackgroundColor="#D1E8E2"
Margin="50,10,0,20" Margin="50,10,0,20"
Text="{Binding CurrentUser.Surname} "/> Text="{Binding CurrentUser.Surname} "/>
<Label Text="Mail :" <Label Text="Mail :"
Padding="50,0,0,0" Padding="50,0,0,0"
FontSize="18"/> FontSize="18"/>
<Entry BackgroundColor="#D1E8E2" <Entry BackgroundColor="#D1E8E2"
Margin="50,10,0,20" Margin="50,10,0,20"
IsEnabled="False" IsEnabled="False"
Text="{Binding CurrentUser.Mail}"/> Text="{Binding CurrentUser.Mail}"/>
<!--liste drag and drop--> <!--liste drag and drop-->
</VerticalStackLayout> </VerticalStackLayout>
<VerticalStackLayout Padding="100,0,0,0"> <VerticalStackLayout Padding="100,0,0,0">
<Label Text="Priorités du compte : " TextColor="{AppThemeBinding Light={StaticResource Black}, Dark={StaticResource Gray100}}" <Label Text="Priorités du compte : " TextColor="{AppThemeBinding Light={StaticResource Black}, Dark={StaticResource Gray100}}"
FontSize="20" Padding="15"/> FontSize="20" Padding="15"/>
<FlexLayout BindableLayout.ItemsSource="{Binding PriorityList}" MinimumHeightRequest="80" <FlexLayout BindableLayout.ItemsSource="{Binding PriorityList}" MinimumHeightRequest="80"
BackgroundColor="{StaticResource Primary}" AlignItems="Center" Wrap="Wrap"> BackgroundColor="{StaticResource Primary}" AlignItems="Center" Wrap="Wrap">
<FlexLayout.GestureRecognizers>
<DropGestureRecognizer Drop="DropGestureRecognizer_Drop2" />
</FlexLayout.GestureRecognizers>
<BindableLayout.ItemTemplate> <BindableLayout.ItemTemplate>
<DataTemplate> <DataTemplate>
<Border HorizontalOptions="Center" WidthRequest="190" HeightRequest="30" BackgroundColor="{StaticResource Secondary}" Margin="10,0,10,0"> <Border HorizontalOptions="Center" WidthRequest="190" HeightRequest="30" BackgroundColor="{StaticResource Secondary}" Margin="10,0,10,0">
@ -80,11 +77,11 @@
</DataTemplate> </DataTemplate>
</BindableLayout.ItemTemplate> </BindableLayout.ItemTemplate>
</FlexLayout> </FlexLayout>
</VerticalStackLayout> </VerticalStackLayout>
</HorizontalStackLayout> </HorizontalStackLayout>
</StackLayout> </StackLayout>
</ScrollView> </ScrollView>
</local:ContainerBase.MyContent> </local:ContainerBase.MyContent>
</local:ContainerBase> </local:ContainerBase>
</ContentPage> </ContentPage>

Loading…
Cancel
Save