]> git.evergreen-ils.org Git - Evergreen.git/commit
LP#1917396 - Staff Curbside Scheduling UTC Issues
authorJosh Stompro <stompro@stompro.org>
Fri, 5 Mar 2021 01:09:44 +0000 (19:09 -0600)
committerGalen Charlton <gmc@equinoxOLI.org>
Thu, 12 Aug 2021 22:23:45 +0000 (18:23 -0400)
commit5e9974b4d594852878f920141356da254846f3b1
tree35845a35e590374e9f08e69fed6add051de3272d
parentc2f3a0ab095adf6c820ba0a7f79fcb68b62e0ad0
LP#1917396 - Staff Curbside Scheduling UTC Issues

When a staff person tries to schedule curbside appointments
after their UTC equivalent time moves to the next day, the
timeslots for the next day are shown, and appointments get
made for the next day.

For example, when CST is the local timezone (UTC-6), after 6pm
appointments for the current day are scheduled for the next day.
Appointments for the next day get scheduled for the day after.

This happens because toISOString is used to grab the current date,
but toISOString always returns UTC time.  The date widget will show
the correct date, but the time slots will actually be for the next
day.  This is more noticeable if days have different schedules.

Another clue is that the time slot selector will show all timeslots for
the day, not just the ones that are upcoming.

Testing Plan:

1. Enable curbside for test location, and set org unit hours to
   be at least through 8pm for open hours.

2. Wait until after 4PM (Pacific), 6pm CST, 7PM EST, or
   change your computer clock.

3. Try to schedule an appointment for the current day.

4. The appointment should get scheduled for the next day.

5. Apply the fix.

6. Try to schedule another appointment and see that the correct
   date gets selected.

Signed-off-by: Josh Stompro <stompro@stompro.org>
Signed-off-by: Terran McCanna <tmccanna@georgialibraries.org>
Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
Open-ILS/web/js/ui/default/staff/circ/curbside/directives/schedule_pickup.js