root / GES_PAC / View / EnterAnimalView.xaml @ 957b1f34
Historique | Voir | Annoter | Télécharger (3,602 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 |
xmlns:tools="clr-namespace:GES_PAC.View.Tools" |
6 |
xmlns:controls="clr-namespace:GES_PAC.Controls" |
7 |
x:Class="GES_PAC.View.EnterAnimalView" |
8 |
x:DataType="vm:EnterAnimalViewModel"> |
9 |
|
10 |
<Grid>
|
11 |
<StackLayout BackgroundColor="White" Spacing="50"> |
12 |
<tools:ConnectionIndicatorView /> |
13 |
<ScrollView>
|
14 |
|
15 |
<VerticalStackLayout Grid.Row="1" Spacing="30"> |
16 |
|
17 |
<Label Text="{Binding Titre}" |
18 |
FontSize="20" |
19 |
FontAttributes="Bold" |
20 |
HorizontalOptions="Center" /> |
21 |
<VerticalStackLayout Spacing="15" WidthRequest="300"> |
22 |
|
23 |
<!-- Num RFID -->
|
24 |
<VerticalStackLayout>
|
25 |
|
26 |
<Label Text="Numéro RFID" FontSize="14" TextColor="Gray" FontAttributes="Bold"/> |
27 |
<Entry Text="{Binding NumRFID}" FontSize="16" TextColor="Black" Placeholder="12345" Keyboard="Numeric"/> |
28 |
<Label Text="Min. 5 chiffres" |
29 |
FontSize="12" |
30 |
TextColor="Red" |
31 |
IsVisible="{Binding NumRFIDError}"/> |
32 |
|
33 |
</VerticalStackLayout>
|
34 |
|
35 |
<!-- Poids -->
|
36 |
<VerticalStackLayout>
|
37 |
<Label Text="Poids (kg)" FontSize="14" TextColor="Gray" FontAttributes="Bold"/> |
38 |
<controls:DoubleEntry Text="{Binding Poids, Mode=OneWayToSource}" Placeholder="75,0"/> |
39 |
<Label Text="Entrez une valeur" |
40 |
FontSize="12" |
41 |
TextColor="Red" |
42 |
IsVisible="{Binding PoidsError}"/> |
43 |
</VerticalStackLayout>
|
44 |
|
45 |
</VerticalStackLayout>
|
46 |
</VerticalStackLayout>
|
47 |
</ScrollView>
|
48 |
<StackLayout
|
49 |
Margin="10" |
50 |
HorizontalOptions="CenterAndExpand" |
51 |
Orientation="Horizontal" |
52 |
VerticalOptions="FillAndExpand"> |
53 |
|
54 |
<Button
|
55 |
Text="Enregistrer" |
56 |
Command="{Binding EnterAnimalCommand}" |
57 |
Style="{StaticResource btnNormal}" |
58 |
IsEnabled="{Binding IsFormValid}" |
59 |
VerticalOptions="End"/> |
60 |
</StackLayout>
|
61 |
</StackLayout>
|
62 |
<Grid Grid.RowSpan="1" IsVisible="{Binding IsBusy}"> |
63 |
<Border StrokeThickness="0" |
64 |
Background="Black" |
65 |
Opacity="0.5" |
66 |
Padding="20" |
67 |
WidthRequest="160" |
68 |
HeightRequest="160" |
69 |
HorizontalOptions="Center" |
70 |
VerticalOptions="Center" |
71 |
StrokeShape="RoundRectangle 20"> |
72 |
|
73 |
<VerticalStackLayout HorizontalOptions="Center" VerticalOptions="Center"> |
74 |
<ActivityIndicator IsRunning="True" Color="White" /> |
75 |
<Label Text="Chargement..." |
76 |
FontSize="14" |
77 |
TextColor="white" |
78 |
HorizontalOptions="Center"/> |
79 |
</VerticalStackLayout>
|
80 |
</Border>
|
81 |
</Grid>
|
82 |
</Grid>
|
83 |
|
84 |
</ContentPage>
|