Apr 01 2019 05:46 AM
Apr 01 2019 05:46 AM
I'm trying to setup a simple car booking site using SharePoint Online. Currently, I have a list library called 'Cars', which stores a list of all the company cars, and a calendar called 'Car Bookings', which displays what cars are booked for a given day.
Let's say on April 1st I add an event to my calendar (i.e. a car booking) and select 'Nissan' from the lookup field which links to my list library of cars. The Nissan is now booked and logged in the calendar for April 1st.
If I add another event item (car booking) to April 1st, it still allows me to choose 'Nissan' from the list, despite it already being booked.
Is there any way so that when you're selecting the car, it removes the option to pick a car if it's already booked for the chosen date/time?
Sorry if this seems complicated, I'm not sure how else to explain it.
Apr 01 2019 05:49 AM
@Toby McDaidHow does the system know that the car is booked? You need to have something like an IsBooked field that gets set to true when it is booked and then have some logic to evaluate this setting.
Apr 01 2019 05:58 AM
@Dean Gross I think I would probably run into more issues. If, for example, I booked a car on April 1st and it sets IsBooked to true, it would then prevent me from making a booking of the same car for, say, April 20th. It would also require manually resetting cars back to false once they've been used.
Apr 01 2019 06:01 AMSolution
Apr 01 2019 07:33 AM
@Toby McDaid, @Dean Gross is right--what you want to achieve is not a trivial function in SharePoint and you will need a Flow to manage it. If you want to recognize something as booked, that would also mean you'd have to take steps to mark it as available. What you want is achievable, though it will require some tinkering with Flow and probably another List or two to get it right.
Mar 11 2020 09:06 PM
Did you ever find a solution for this @Toby McDaid ?
I'm investigating a car booking solution and would like to know if you found a good solution. I'm thinking I might need to do a PowerApp.