//Displays the campgrounds for a specific park and options to continue public void DisplayCampgrounds(int park_id, string park_name) { IList <Campground> campgrounds = campgroundSqlDAO.GetCampgroundsByPark(park_id); bool done = false; while (!done) { Console.Clear(); Console.WriteLine("Park Campgrounds"); Console.WriteLine(park_name); DisplayHelper.DisplayCampgrounds(campgrounds); int cgChoice = CLIHelper.GetInteger("\nSelect a Campground to reserve (or enter 0 to return): "); if (cgChoice != 0) { DateTime[] dateRange = CLIHelper.GetDateRange("Please enter your planned arrival date: ", "Please enter your planned departure date : "); DisplayOpenSites(campgrounds[cgChoice - 1].Campground_Id, dateRange[0], dateRange[1], campgrounds[cgChoice - 1].Daily_fee); } else { done = true; } } }
//Displays the information for the selected park and menu options to continue public void ParkInfoMenu(int park_id) { Console.Clear(); bool done = false; while (!done) { DisplayHelper.DisplayParkInfo(Parks[park_id]); int infoChoice = CLIHelper.GetInteger("\nSelect an option:\n\t1) View Campgrounds\n\t2) Show all available Campsites for this Park\n\t" + "3) Advanced Search of All Campgrounds in This Park \n\t4) Diplay Reservations in this park for the next 30 days " + "\n\t5) Return to Previous Menu\n\nEnter Choice: "); if (infoChoice == 1) { DisplayCampgrounds(Parks[park_id].Park_id, Parks[park_id].Name); } else if (infoChoice == 2) { DateTime[] dateRange = CLIHelper.GetDateRange("Please enter your planned arrival date: ", "Please enter your planned departure date : "); DisplayOpenSitesEntirePark(Parks[park_id].Park_id, dateRange[0], dateRange[1]); } else if (infoChoice == 3) { DateTime[] dateRange = CLIHelper.GetDateRange("Please enter your planned arrival date: ", "Please enter your planned departure date : "); AdvancedSearchForSiteByCampground(Parks[park_id].Park_id, dateRange[0], dateRange[1]); } else if (infoChoice == 4) { IList <Reservation> reservations = reservationSqlDAO.GetReservationsNext30ByPark(Parks[park_id].Park_id); DisplayHelper.DisplayReservations(reservations); } else { done = true; } } }