From 33c182574cf4154636e520b8f597359c6a8c777d Mon Sep 17 00:00:00 2001 From: soukainna Date: Mon, 27 Feb 2023 14:10:26 +0100 Subject: [PATCH] add events stats --- web/layouts/administration/events_stats.html | 107 +++++++++++++++ web/layouts/administration/home.html | 4 +- .../administration/vehicles_stats.html | 128 ++++++++++++++++++ web/layouts/members/membersList.html | 13 +- web/layouts/vehicles/bookings-list.html | 19 ++- .../unbooking-display.html | 19 +++ 6 files changed, 283 insertions(+), 7 deletions(-) create mode 100644 web/layouts/administration/events_stats.html create mode 100644 web/layouts/administration/vehicles_stats.html diff --git a/web/layouts/administration/events_stats.html b/web/layouts/administration/events_stats.html new file mode 100644 index 0000000..eeeeaf2 --- /dev/null +++ b/web/layouts/administration/events_stats.html @@ -0,0 +1,107 @@ +{{define "content"}} + +
+
+
+

La liste des événements

+
+ +
+
+
+
+
+
+
+ + + + + + + + + + + + + {{range .ViewState.events}} + + + + + + + + + + + + + + {{end}} + + +
+ Dispositif + + Structure + + Lieu + + Dates + + Places disponibles + + Bénéficiaires positionnés + + Actions +
+ +
{{.Name}}
+
{{.Type}}
+
+ +
+ {{range .Owners}} + {{if (index $.ViewState.groups .)}} + {{(index $.ViewState.groups .).Data.name}} + {{end}} + {{end}} +
+
+
{{if .Data.address}}{{.Data.address.properties.label}}{{end}}
+
+
+ {{if eq .Startdate .Enddate}} + Le {{(timeFrom .Startdate).Format "02/01/2006"}} + {{else}} + Du {{(timeFrom .Startdate).Format "02/01/2006"}}
Au {{(timeFrom .Enddate).Format "02/01/2006"}} + {{end}} +
+
+ {{if ne .RemainingSubscriptions 999}} +
{{.RemainingSubscriptions}}
+ {{end}} +
+
+ {{range .Subscriptions}} + + {{end}} +
+
+ Voir +
+
+
+
+
+
+{{end}} \ No newline at end of file diff --git a/web/layouts/administration/home.html b/web/layouts/administration/home.html index 1418344..f314c63 100644 --- a/web/layouts/administration/home.html +++ b/web/layouts/administration/home.html @@ -14,7 +14,7 @@
- Bénéficiaires + Bénéficiaires

{{len .ViewState.beneficiaries }} bénéficiaires

@@ -28,7 +28,7 @@
- Évenements + Évenements

{{len .ViewState.events}} évenements

diff --git a/web/layouts/administration/vehicles_stats.html b/web/layouts/administration/vehicles_stats.html new file mode 100644 index 0000000..57834fc --- /dev/null +++ b/web/layouts/administration/vehicles_stats.html @@ -0,0 +1,128 @@ +{{define "content"}} +
+
+
+

La liste des voitures

+
+ +
+
+ +
+
+
+
+
+ + + + + + + + + + + + + + + {{range .ViewState.vehicles}} + + + + + + + + + + + {{end}} + +
+ Statut Réservation + + Organisation + + Numéro (Immat / Bicycode) + + Type + + Modèle + + Lieu + + Actions +
+
+ {{if not .Bookings}} + + Disponible + + {{else}} + {{range .Bookings}} + {{if .Data.administrator_unavailability}} + + Retiré + + {{else}} + {{if eq .Status 1 }} + + A venir + + {{else if eq .Status 0 }} + + En cours + + {{else}} + + Disponible + + {{end}} + {{end}} + {{end}} + {{end}} +
+
+ {{range .Bookings}} +
{{.Data.booked_by.group.name}}
+ + + {{end}} +
+
{{.Data.licence_plate}}
+
+
+ {{.Type}} + {{if eq .Type "Voiture"}} + {{ if .Data.automatic}} (boite auto){{ end }} + {{end}} +
+
+
{{.Data.name}}
+
+
{{if .Data.address}}{{.Data.address.properties.label}}{{end}}
+
+ Voir +
+
+
+
+
+
+ + +{{end}} + + \ No newline at end of file diff --git a/web/layouts/members/membersList.html b/web/layouts/members/membersList.html index e5b2c84..73e3fd0 100644 --- a/web/layouts/members/membersList.html +++ b/web/layouts/members/membersList.html @@ -1,15 +1,20 @@ {{define "content"}}
-

Les membres de l'organisation {{.Group.Data.name}}

-
-

+

La listes des référents

+
+
-
-

Réservations

+
+
+

Réservations

+
+ +
@@ -64,6 +76,11 @@ {{end}} {{end}} + {{if not .bookings}} + + Disponible + + {{end}}
{{(index $.ViewState.vehicles_map .Vehicleid).Type}}
diff --git a/web/layouts/vehicles_management/unbooking-display.html b/web/layouts/vehicles_management/unbooking-display.html index 8b5de9d..7552f9a 100644 --- a/web/layouts/vehicles_management/unbooking-display.html +++ b/web/layouts/vehicles_management/unbooking-display.html @@ -1,4 +1,23 @@ {{define "content"}} +
+

Voitures disponibles

+ + + +