I’m creating a doctor app and want the doctor to create time slots for his appointment times,
I’m using the date picker to create time slots and the calendar component to view the time slots as events for the customer to pick from, but there are two problems facing me:
I want the selected time in the date picker to be available every day in the calendar component not only for the specific date it was selected for (it’s not efficient to let the doctor choose appointment times every day)
I want the selectable days to be only three days from the current day in the calendar component.
is my approach of doing it is right, or should I change…
this is the final step of my app, any help would be appreciated.
thanks for the fast reply,
I tried building a custom list of times but there was a problem also, I created two lists of timeslots for today and tomorrow and added true/false parameter for each timeslot to check if it was booked or no, if someone booked a timeslot in tomorrow list then in the next day that booked time slot will be in the today list and the timeslot in the tomorrow list will be cleared because days are moving on, you get my idea.
so is there a fix for this or another approach for booking.
As I can see that this is critical feature to your app and should be resolved before anything else.
Calendar component is using collection to fill its data, so either you follow the rules by creating each date for any foreseeable future, or you create your own rules by creating calendar simulation that can show as if the other dates have slots, so the relationship between calendar and timeslots is reversed or limited, your choice, your rules.
It seems this is the option you need to experiment, as only custom list allows components inside it to have its own visibility and layout manipulation.