Compare commits
35 Commits
After Width: | Height: | Size: 15 KiB |
@ -0,0 +1,40 @@
|
||||
<mxfile host="app.diagrams.net" modified="2023-09-20T12:17:57.703Z" agent="Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/115.0" etag="sVb7Rw98gNrLW8AO19HB" version="21.7.5" type="device">
|
||||
<diagram name="Page-1" id="e78aO4FO6e_sPu6jAY4w">
|
||||
<mxGraphModel dx="2261" dy="726" grid="1" gridSize="10" guides="1" tooltips="1" connect="1" arrows="1" fold="1" page="1" pageScale="1" pageWidth="827" pageHeight="1169" math="0" shadow="0">
|
||||
<root>
|
||||
<mxCell id="0" />
|
||||
<mxCell id="1" parent="0" />
|
||||
<mxCell id="XgXC638uMGpcY1R6JfbD-9" style="edgeStyle=orthogonalEdgeStyle;rounded=0;orthogonalLoop=1;jettySize=auto;html=1;" edge="1" parent="1" source="XgXC638uMGpcY1R6JfbD-1" target="XgXC638uMGpcY1R6JfbD-3">
|
||||
<mxGeometry relative="1" as="geometry" />
|
||||
</mxCell>
|
||||
<mxCell id="XgXC638uMGpcY1R6JfbD-1" value="MAUI" style="rounded=1;whiteSpace=wrap;html=1;" vertex="1" parent="1">
|
||||
<mxGeometry x="220" y="370" width="120" height="60" as="geometry" />
|
||||
</mxCell>
|
||||
<mxCell id="XgXC638uMGpcY1R6JfbD-2" value="<div align="left">Contient:<br>- Pages/Vues</div><div align="left">- VM applicative<br></div>" style="text;html=1;strokeColor=none;fillColor=none;align=left;verticalAlign=top;whiteSpace=wrap;rounded=0;" vertex="1" parent="1">
|
||||
<mxGeometry x="220" y="440" width="250" height="100" as="geometry" />
|
||||
</mxCell>
|
||||
<mxCell id="XgXC638uMGpcY1R6JfbD-3" value="Model" style="rounded=1;whiteSpace=wrap;html=1;" vertex="1" parent="1">
|
||||
<mxGeometry x="-110" y="370" width="120" height="60" as="geometry" />
|
||||
</mxCell>
|
||||
<mxCell id="XgXC638uMGpcY1R6JfbD-12" style="edgeStyle=orthogonalEdgeStyle;rounded=0;orthogonalLoop=1;jettySize=auto;html=1;" edge="1" parent="1" source="XgXC638uMGpcY1R6JfbD-4" target="XgXC638uMGpcY1R6JfbD-3">
|
||||
<mxGeometry relative="1" as="geometry" />
|
||||
</mxCell>
|
||||
<mxCell id="XgXC638uMGpcY1R6JfbD-4" value="Stub" style="rounded=1;whiteSpace=wrap;html=1;" vertex="1" parent="1">
|
||||
<mxGeometry x="-110" y="160" width="120" height="60" as="geometry" />
|
||||
</mxCell>
|
||||
<mxCell id="XgXC638uMGpcY1R6JfbD-5" value="WebService" style="rounded=1;whiteSpace=wrap;html=1;" vertex="1" parent="1">
|
||||
<mxGeometry x="70" y="220" width="120" height="60" as="geometry" />
|
||||
</mxCell>
|
||||
<mxCell id="XgXC638uMGpcY1R6JfbD-11" style="edgeStyle=orthogonalEdgeStyle;rounded=0;orthogonalLoop=1;jettySize=auto;html=1;" edge="1" parent="1" source="XgXC638uMGpcY1R6JfbD-6" target="XgXC638uMGpcY1R6JfbD-3">
|
||||
<mxGeometry relative="1" as="geometry" />
|
||||
</mxCell>
|
||||
<mxCell id="XgXC638uMGpcY1R6JfbD-6" value="VMWrapper" style="rounded=1;whiteSpace=wrap;html=1;" vertex="1" parent="1">
|
||||
<mxGeometry x="-290" y="370" width="120" height="60" as="geometry" />
|
||||
</mxCell>
|
||||
<mxCell id="XgXC638uMGpcY1R6JfbD-7" value="<div align="left">Contient:<br>- Interface (pour récup les data)<br></div>" style="text;html=1;strokeColor=none;fillColor=none;align=left;verticalAlign=top;whiteSpace=wrap;rounded=0;" vertex="1" parent="1">
|
||||
<mxGeometry x="-120" y="440" width="250" height="100" as="geometry" />
|
||||
</mxCell>
|
||||
</root>
|
||||
</mxGraphModel>
|
||||
</diagram>
|
||||
</mxfile>
|
@ -0,0 +1,19 @@
|
||||
using BookApp.ViewModel;
|
||||
using VMWrapper;
|
||||
|
||||
namespace BookApp.Composants
|
||||
{
|
||||
public partial class CollectionFiltrage : ContentView
|
||||
{
|
||||
public CollectionFiltrage()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public CollectionFiltrage(FilterViewModel data)
|
||||
: this()
|
||||
{
|
||||
BindingContext = data;
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,84 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<ContentView xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
||||
xmlns:composants="clr-namespace:BookApp.Composants"
|
||||
xmlns:model="clr-namespace:Model;assembly=Model"
|
||||
xmlns:usecase="clr-namespace:BookApp.UseCase"
|
||||
x:Name="ThisPage"
|
||||
x:Class="BookApp.Composants.GroupCollection">
|
||||
|
||||
<ContentView.Resources>
|
||||
<ResourceDictionary>
|
||||
<usecase:AuthorsListToStringConverter x:Key="authorsConverter"/>
|
||||
</ResourceDictionary>
|
||||
</ContentView.Resources>
|
||||
|
||||
<CollectionView ItemsSource="{Binding AuteurGroups}" IsGrouped="True" SelectionMode="Single" x:Name="groupCollectionView">
|
||||
<CollectionView.GroupHeaderTemplate>
|
||||
<DataTemplate x:DataType="model:Author">
|
||||
<Label Text="{Binding Name}"
|
||||
FontFamily="SF-Compact-Display-Semibold"
|
||||
BackgroundColor="LightGrey"
|
||||
TextColor="Gray"
|
||||
Padding="5"/>
|
||||
</DataTemplate>
|
||||
</CollectionView.GroupHeaderTemplate>
|
||||
<CollectionView.ItemTemplate>
|
||||
<DataTemplate x:DataType="model:Book">
|
||||
<SwipeView Style="{StaticResource StyleCollectionStack}">
|
||||
<SwipeView.LeftItems>
|
||||
<SwipeItems>
|
||||
<SwipeItem Text="Favorite"
|
||||
IconImageSource="favorite.png"
|
||||
BackgroundColor="LightGreen"/>
|
||||
<SwipeItem Text="Delete"
|
||||
IconImageSource="delete.png"
|
||||
BackgroundColor="LightPink"
|
||||
Command="{Binding Source={x:Reference groupCollectionView}, Path=BindingContext.RemoveBookCommand}"
|
||||
CommandParameter="{Binding Id}"/>
|
||||
</SwipeItems>
|
||||
</SwipeView.LeftItems>
|
||||
<StackLayout>
|
||||
<Grid>
|
||||
<Grid.GestureRecognizers>
|
||||
<TapGestureRecognizer Command="{Binding Source={x:Reference ThisPage}, Path=Nav.BookDetailCommand}"
|
||||
CommandParameter="{Binding Id}"/>
|
||||
</Grid.GestureRecognizers>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Image Grid.Column="0"
|
||||
Source="{Binding ImageLarge}"
|
||||
HeightRequest="125"
|
||||
WidthRequest="125"
|
||||
Margin="0,10,0,10"/>
|
||||
<StackLayout Grid.Column="1">
|
||||
<Label Text="{Binding Title}"
|
||||
FontFamily="SF-Compact-Display-Bold"
|
||||
FontSize="18"
|
||||
TextColor="Black"/>
|
||||
<Label Text="{Binding Authors, Converter={StaticResource authorsConverter}}" FontFamily="SF-Compact-Display-Semibold" TextColor="Black"/>
|
||||
<Label
|
||||
TextColor="SlateGray"
|
||||
Text="{Binding Status}"/>
|
||||
|
||||
<StackLayout Margin="0,10" Orientation="Horizontal" VerticalOptions="EndAndExpand">
|
||||
<Image Source="empty_star.svg" WidthRequest="25" HeightRequest="25"/>
|
||||
<Image Source="empty_star.svg" WidthRequest="25" HeightRequest="25"/>
|
||||
<Image Source="empty_star.svg" WidthRequest="25" HeightRequest="25"/>
|
||||
<Image Source="empty_star.svg" WidthRequest="25" HeightRequest="25"/>
|
||||
<Image Source="empty_star.svg" WidthRequest="25" HeightRequest="25"/>
|
||||
</StackLayout>
|
||||
</StackLayout>
|
||||
</Grid>
|
||||
<Rectangle Margin="25,0,0,10" HeightRequest="1" BackgroundColor="LightGray" VerticalOptions="End" />
|
||||
</StackLayout>
|
||||
</SwipeView>
|
||||
</DataTemplate>
|
||||
</CollectionView.ItemTemplate>
|
||||
</CollectionView>
|
||||
</ContentView>
|
@ -0,0 +1,21 @@
|
||||
using BookApp.ViewModel;
|
||||
using VMWrapper;
|
||||
|
||||
namespace BookApp.Composants
|
||||
{
|
||||
public partial class GroupCollection : ContentView
|
||||
{
|
||||
public ViewModelNavigation Nav { get; } = new ViewModelNavigation();
|
||||
|
||||
public GroupCollection()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public GroupCollection(BooksViewModel data)
|
||||
: this()
|
||||
{
|
||||
BindingContext = data;
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,48 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<ContentView xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
||||
x:Class="BookApp.Composants.ToggleSwitchView">
|
||||
<Grid
|
||||
VerticalOptions="FillAndExpand"
|
||||
HorizontalOptions="FillAndExpand"
|
||||
Padding="10">
|
||||
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="*" />
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<StackLayout
|
||||
Orientation="Horizontal"
|
||||
HorizontalOptions="Center"
|
||||
VerticalOptions="Center"
|
||||
Grid.Row="0"
|
||||
Spacing="30">
|
||||
|
||||
<Label
|
||||
x:Name="OffLabel"
|
||||
Text="Prêts"
|
||||
Opacity="0.25"
|
||||
VerticalTextAlignment="Center"/>
|
||||
|
||||
<Grid
|
||||
VerticalOptions="Center"
|
||||
HorizontalOptions="Center"
|
||||
Scale="1.5">
|
||||
|
||||
<Switch
|
||||
x:Name="ToggleSwitch"
|
||||
Toggled="OnToggled" />
|
||||
|
||||
</Grid>
|
||||
|
||||
<Label
|
||||
x:Name="OnLabel"
|
||||
Text="Emprunts"
|
||||
Opacity="0.25"
|
||||
VerticalTextAlignment="Center"/>
|
||||
</StackLayout>
|
||||
|
||||
<!-- Autres éléments de l'interface utilisateur si nécessaire -->
|
||||
</Grid>
|
||||
</ContentView>
|
@ -0,0 +1,16 @@
|
||||
using BookApp.ViewModel;
|
||||
using System.Diagnostics;
|
||||
|
||||
namespace BookApp.Pages
|
||||
{
|
||||
public partial class DetailBook : ContentPage
|
||||
{
|
||||
public ViewModelNavigation Nav { get; } = new ViewModelNavigation();
|
||||
|
||||
public DetailBook(ViewModelDetailProvider VMProvider)
|
||||
{
|
||||
InitializeComponent();
|
||||
BindingContext = VMProvider;
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,17 @@
|
||||
using BookApp.ViewModel;
|
||||
using System.Windows.Input;
|
||||
using VMWrapper;
|
||||
|
||||
namespace BookApp.Pages
|
||||
{
|
||||
public partial class EmpruntsPrets : ContentPage
|
||||
{
|
||||
public ViewModelNavigation Nav { get; } = new ViewModelNavigation();
|
||||
|
||||
public EmpruntsPrets(BooksViewModel data)
|
||||
{
|
||||
InitializeComponent();
|
||||
BindingContext = data;
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
using BookApp.ViewModel;
|
||||
using System.Diagnostics;
|
||||
using VMWrapper;
|
||||
|
||||
namespace BookApp.Pages
|
||||
{
|
||||
[QueryProperty(nameof(Title), "Title")]
|
||||
public partial class Filtrage : ContentPage
|
||||
{
|
||||
private readonly string Title;
|
||||
|
||||
public ViewModelNavigation Nav { get; } = new ViewModelNavigation();
|
||||
|
||||
public Filtrage(FilterViewModel data)
|
||||
{
|
||||
InitializeComponent();
|
||||
BindingContext = data;
|
||||
}
|
||||
}
|
||||
}
|
Before Width: | Height: | Size: 228 B After Width: | Height: | Size: 228 B |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 785 B After Width: | Height: | Size: 785 B |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 703 B After Width: | Height: | Size: 703 B |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 3.8 KiB After Width: | Height: | Size: 3.8 KiB |
Before Width: | Height: | Size: 465 B After Width: | Height: | Size: 465 B |
Before Width: | Height: | Size: 560 B After Width: | Height: | Size: 560 B |
After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 12 KiB |
Before Width: | Height: | Size: 343 B After Width: | Height: | Size: 343 B |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 179 B After Width: | Height: | Size: 179 B |
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 714 B After Width: | Height: | Size: 714 B |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 934 B After Width: | Height: | Size: 934 B |
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 761 B After Width: | Height: | Size: 761 B |
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 564 B After Width: | Height: | Size: 564 B |
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 2.1 KiB |
Before Width: | Height: | Size: 921 B After Width: | Height: | Size: 921 B |
Before Width: | Height: | Size: 2.3 KiB After Width: | Height: | Size: 2.3 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |