[Entry] Appointment Scheduler
Doug Black May 8
What I built
This scheduler allows you to create appointments to be scheduled in different rooms. You can create rooms, create appointments to be added directly to the scheduler, move appointments between rooms and time slots on the scheduler, schedule appointments without a time to be added later (drag and drop them on).
The scheduler uses sockets to communicate with others on the schedule, so that appointments time slots lock out when you are scheduling there, or when you are editing an appointment.
Project currently lives here: dev.to Scheduler: scheduler.dougblackjr.com
Note: This app is made for desktop viewing.
Link to Code
How I built it (what's the stack? did I run into issues or discover something new along the way?)
There were two challenges.
The first was locking the time slots on the calendar, which have no backend model created for it. In order to show someone across the ocean that the time slot is being edited, and to avoid overlap, I used Redis to create a key that specifically targets that slot on that day for those times for that particular resource.
The second, and possibly more challenging, was dealing with time zones. When I had tried this in the past, I relied heavily on the browser to deal with time. But if someone was halfway around the world, the time slots would get all borky. Therefore, I throw pretty much everything at the server in order to deal with timing.
Here's my random dump of thoughts:
- Pusher made this a thousand times easier.
- Though I love my friends around the world, if y'all could move to Eastern Standard time, I would appreciate it.
- I created this because scheduling is hard. I'm grateful for the already created things that made this possible. Please steal my code and make it better.
- Thank you to dev.to for being a positive community and for making this all possible!