From 795066b6e5f1a865e79484878919df9e73373774 Mon Sep 17 00:00:00 2001 From: soukainna Date: Fri, 3 Mar 2023 17:23:52 +0100 Subject: [PATCH] add unbooking vehicles --- renderer/vehicle-management.go | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/renderer/vehicle-management.go b/renderer/vehicle-management.go index dee0dc6..05bacce 100644 --- a/renderer/vehicle-management.go +++ b/renderer/vehicle-management.go @@ -88,3 +88,14 @@ func (renderer *Renderer) VehicleManagementBookingDisplay(w http.ResponseWriter, // renderer.Render("fleet display Unbooking vehicle", w, r, files, state) // } + +func (renderer *Renderer) UnbookingVehicles(w http.ResponseWriter, r *http.Request, vehicles []fleetsstorage.Vehicle) { + files := renderer.ThemeConfig.GetStringSlice("views.vehicles_management.unbooking_display.files") + state := NewState(r, renderer.ThemeConfig, vehiclesmanagementMenu) + state.ViewState = map[string]any{ + + "vehicles": vehicles, + } + + renderer.Render("fleet display Unbooking vehicle", w, r, files, state) +}