Statistiques
| Branche: | Révision:

root / GES_PAC / View / CreatePersonView.xaml @ eac868a1

Historique | Voir | Annoter | Télécharger (3,741 ko)

1
<?xml version="1.0" encoding="utf-8" ?>
2
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
3
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
4
             xmlns:vm="clr-namespace:GES_PAC.ViewModel"
5
             x:Class="GES_PAC.View.CreatePersonView"
6
             x:DataType="vm:CreatePersonViewModel">
7

    
8
    <Grid Padding="20" RowDefinitions="Auto, *">
9

    
10
        <Button Text="Retour"
11
                BackgroundColor="DarkRed"
12
                TextColor="White"
13
                CornerRadius="10"
14
                Padding="10"
15
                FontSize="14"
16
                HorizontalOptions="Start"
17
                VerticalOptions="Start"
18
                Command="{Binding ReturnCommand}"/>
19

    
20
        <VerticalStackLayout Grid.Row="1" Spacing="20"
21
                             VerticalOptions="CenterAndExpand"
22
                             HorizontalOptions="Center">
23

    
24
            <Label Text="Informations du technicien"
25
                FontSize="20"
26
                FontAttributes="Bold"
27
                HorizontalOptions="Center" />
28

    
29
            <VerticalStackLayout Spacing="15" WidthRequest="300">
30

    
31
                <!-- Nom -->
32
                <VerticalStackLayout>
33
                    <Label Text="Nom :"
34
                        FontSize="14"
35
                        TextColor="Gray"
36
                        FontAttributes="Bold"/>
37

    
38
                    <Entry Text="{Binding Nom}"
39
                        FontSize="16"
40
                        TextColor="Black"
41
                        Placeholder="Entrer le nom"
42
                        Keyboard="Text"
43
                        MaxLength="25"/>
44

    
45
                    <Label Text="Min. 3 caractères"
46
                        FontSize="12"
47
                        TextColor="Red"
48
                        IsVisible="{Binding NomError}"/>
49
                </VerticalStackLayout>
50

    
51
                <!-- Prénom -->
52
                <VerticalStackLayout>
53
                    <Label Text="Prénom :"
54
                        FontSize="14"
55
                        TextColor="Gray"
56
                        FontAttributes="Bold"/>
57

    
58
                    <Entry Text="{Binding Prenom}"
59
                        FontSize="16"
60
                        TextColor="Black"
61
                        Placeholder="Entrer le prénom"
62
                        Keyboard="Text"
63
                        MaxLength="25"/>
64

    
65
                    <Label Text="Min. 3 caractères"
66
                        FontSize="12"
67
                        TextColor="Red"
68
                        IsVisible="{Binding PrenomError}"/>
69
                </VerticalStackLayout>
70

    
71
                <!-- Email -->
72
                <VerticalStackLayout>
73
                    <Label Text="Email :"
74
                        FontSize="14"
75
                        TextColor="Gray"
76
                        FontAttributes="Bold"/>
77

    
78
                    <Entry Text="{Binding Email}"
79
                        FontSize="16"
80
                        TextColor="Black"
81
                        Placeholder="Entrer l'adresse email"
82
                        Keyboard="Email"
83
                        MaxLength="50"/>
84

    
85
                    <Label Text="Min. 10 caractères"
86
                        FontSize="12"
87
                        TextColor="Red"
88
                        IsVisible="{Binding EmailError}"/>
89
                </VerticalStackLayout>
90
            </VerticalStackLayout>
91

    
92
            <Button Text="Enregistrer"
93
                BackgroundColor="Green"
94
                TextColor="White"
95
                CornerRadius="10"
96
                Padding="15"
97
                FontSize="16"
98
                HorizontalOptions="Center"
99
                WidthRequest="180"
100
                IsEnabled="{Binding IsFormValid}"
101
                Command="{Binding CreatePersonCommand}"/>
102

    
103
        </VerticalStackLayout>
104

    
105
    </Grid>
106

    
107
</ContentPage>