private void Park() { ui.Clear(); ui.Meny(handler.IsGarageFull, GetParkMenyOptions(), "Park meny"); if (handler.IsGarageFull) { return; } VehicleType vehicleType = (VehicleType)ChooseVehicle(search: false); var vehicleProp = vehicleType.GetPropsForType(); var vehicle = handler.GetVehicle(vehicleProp); ui.Print(handler.Park(vehicle) ? $"[{vehicleType}] with registration number:{vehicle.RegNo} parked" : $"Something failed"); }
private void Park() { ui.Clear(); ui.ParkMeny(handler.IsFull, GetParkMenyOptions()); if (handler.IsFull) { return; } var vehicleType = (VehicleType)Util.AskForKey(""); var vehicleProp = vehicleType.GetProps(); var vehicle = handler.GetVehicle(vehicleProp); ui.Print(handler.Park(vehicle) ? $"{vehicleType} {vehicle.RegNo} parked" : $"Something failed"); Console.ReadKey(); }