The project only requires creating a calendar. It is very similar to any booking website calendar. The only thing I require more is that the calendar contains times in addition to dates. The calendar is just to show the bookings. Where the entire day is booked, the calendar will show red. Where there are free slots, the calendar will show green. Where there are no bookings to begin with at that date, the calendar show gray. The chosen date is shown in orange. All of these are shown in the attached image. Once the user selects a free time, it should be highlighted in orange and the date in addition to the time is saved into a variable which I can use later on.
The booking details are taken from a database that is built in the fashion showed in the attached file. The calendar is directly connected to the database. If the database shows that there is a booking and it isn't booked, then it will appear in green. If the database shows a booking but does not show that it is booked, it will be in red. If there is no entry to the facility within that date, it shows gray.