diff --git a/handlers/application/administration.go b/handlers/application/administration.go index 63ca02f..55d40ca 100644 --- a/handlers/application/administration.go +++ b/handlers/application/administration.go @@ -398,21 +398,6 @@ func (h ApplicationHandler) AdminStatVehicles(w http.ResponseWriter, r *http.Req //vehicles := []fleetsstorage.Vehicle{} bookings := []fleetsstorage.Booking{} - //vehicles_map := map[string]fleetsstorage.Vehicle{} - - // for _, vehicle := range resp.Vehicles { - // if filteVehicle(r, vehicle) { - // v := vehicle.ToStorageType() - // vehicles = append(vehicles, v) - // vehicles_map[v.ID] = v - // for _, b := range v.Bookings { - // if b.Status() != fleetsstorage.StatusOld { - // bookings = append(bookings, b) - // } - // } - - // } - // } administrators := []string{} reequest := &fleets.GetVehiclesRequest{ Namespaces: []string{"parcoursmob"}, @@ -458,32 +443,6 @@ func (h ApplicationHandler) AdminStatVehicles(w http.ResponseWriter, r *http.Req } } - //fmt.Println(groups) - //fmt.Println("****************************************************************") - // fmt.Println(vehicles) - // fmt.Println("$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$") - // id := "" - // for _, v := range vehicles { - // id = v.ID - // for _, vv := range v.Bookings { - - // i := 1 - // // fmt.Println("$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$") - // // fmt.Println(vv.Vehicleid) - // // fmt.Println("*********************************************************") - // if id == vv.Vehicleid { - // i++ - // fmt.Println("$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$") - // fmt.Println(vv.Vehicleid) - // fmt.Println("*********************************************************") - // } - // fmt.Println(i) - - // } - // fmt.Println(v.Status) - // fmt.Println("$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$") - //} - // fmt.Println(bookings) sort.Sort(sorting.VehiclesByLicencePlate(vehicles)) sort.Sort(sorting.BookingsByStartdate(bookings)) h.Renderer.AdminStatVehicles(w, r, vehicles, bookings, groups)