diff --git a/config.yaml b/config.yaml index 29a1472..7e2c97d 100644 --- a/config.yaml +++ b/config.yaml @@ -43,6 +43,12 @@ views: list: files: - web/layouts/members/membersList.html + group: + settings: + files: + - web/layouts/administration/_partials/groups_admins.html + - web/layouts/administration/_partials/group_members.html + - web/layouts/group/settings.html vehicles: search: files: @@ -78,6 +84,7 @@ views: fleet_update: files: - web/layouts/_partials/address_autocomplete.html + - web/layouts/agenda/_partials/address.html - web/layouts/vehicles_management/_partials/vehicle-type-select.html - web/layouts/vehicles_management/fleet-update.html booking_display: @@ -205,12 +212,6 @@ views: ko: files: - web/layouts/auth/onboarding-ko.html - group: - settings: - files: - - web/layouts/administration/_partials/groups_admins.html - - web/layouts/administration/_partials/group_members.html - - web/layouts/group/settings.html icons: svg: coopgo:parcoursmob/monogram: diff --git a/web/layouts/vehicles_management/fleet-display.html b/web/layouts/vehicles_management/fleet-display.html index 226f9b1..9714416 100644 --- a/web/layouts/vehicles_management/fleet-display.html +++ b/web/layouts/vehicles_management/fleet-display.html @@ -1,4 +1,5 @@ {{define "content"}} +
@@ -13,11 +14,12 @@

{{.ViewState.vehicle.Data.name}}

+ {{ if eq (index .ViewState.vehicle.Administrators 0) .Group.ID }}
+ {{end}} -
diff --git a/web/layouts/vehicles_management/fleet-update.html b/web/layouts/vehicles_management/fleet-update.html index 88b6770..0b0c2a2 100644 --- a/web/layouts/vehicles_management/fleet-update.html +++ b/web/layouts/vehicles_management/fleet-update.html @@ -1,24 +1,28 @@ {{define "content"}} +{{ if eq (index .ViewState.vehicle.Administrators 0) .Group.ID }}
-

Modifier un véhicule

+

Modifier le véhicule

@@ -47,19 +55,44 @@
- +
- {{template "vehicle_type_select" .}} + + +
+ Automatique +
+
+ {{if .ViewState.vehicle.Data.automatic}} + + {{else}} + + {{end}} +
+
+ +

Ce véhicule a une boite automatique.

+
+
+
+
+ class="block text-sm font-medium text-gray-700">Numéro (Immat, Bicycode, ...) Informations pratiques pour la réservation

- {{ $fieldName := "address" }} - {{ template "address_autocomplete" (dict "FieldName" $fieldName "Address" .ViewState.vehicle.Data.address) }} + {{ $fieldName := "address" }} + {{if .ViewState.vehicle.Data.address}} + {{$default := .ViewState.vehicle.Data.address}} + {{ template "address" dict "FieldName" $fieldName "Default" $default}} + {{else}} + {{ template "address_autocomplete" dict "FieldName" $fieldName}} + {{end}}
- +
- +
@@ -103,4 +141,26 @@
+{{else}} +
+ +
+
+ +
+
+
+ {{.IconSet.Icon "hero:outline/information-circle" "h-6 w-6"}} +
+
+ +
+
+
+ Annuler +
+
+
+
+{{end}} {{end}} \ No newline at end of file