Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(freebusy): time zone handling #6703

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

st3iny
Copy link
Member

@st3iny st3iny commented Feb 10, 2025

Fix #6702

This PR fixes an array of issues in the time zone handling and slot suggestion logic of the free busy or "find a time" modal.

Fixes

  1. Disable the "find a time" button for recurring all day events. (They can't be converted into regular events so it makes no sense.)
  2. Disable slot suggestion for all day events until the user manually selects a slot in the grid. Again, it doesn't make sense to find a time for an all day event. (There will be a hint/help message instead of the automatic slot suggestion.)
  3. Handle time zones correctly. Use the event's start and end time zones. Convert everything to the user's configured time zone to be consistent with the calendar grid.
  4. Use the user's configured time zone to format slot suggestions (and all other displayed dates).

How to reproduce time zone problems?

  1. Create an event (not all day).
  2. Configure some other time zone far away, e.g. something in North America.
  3. Invite someone and open the find a time modal.
  4. Watch the time and date conversion break.
    1. Slots are not formatted correctly according to the user's time zone.
    2. Selected time in the grid does not match the configured time in the event editor.
    3. Selecting some time, saving and returning to the editor will yield a completely different time in the event.

Obligatory meme to cope with reality

image

Signed-off-by: Richard Steinmetz <[email protected]>
@st3iny st3iny added 2. developing Work in progress bug Feature: Scheduling Anything around scheduling meetings, free-busy, resources, attendees and so on labels Feb 10, 2025
@st3iny st3iny self-assigned this Feb 10, 2025
Copy link

codecov bot commented Feb 10, 2025

Codecov Report

Attention: Patch coverage is 27.58621% with 21 lines in your changes missing coverage. Please review.

Project coverage is 22.95%. Comparing base (7b81283) to head (a1adebc).
Report is 11 commits behind head on main.

Files with missing lines Patch % Lines
src/components/Editor/FreeBusy/FreeBusy.vue 0.00% 15 Missing ⚠️
src/views/ContactsMenuAvailability.vue 0.00% 3 Missing ⚠️
src/views/EditSidebar.vue 0.00% 2 Missing ⚠️
src/services/freeBusySlotService.js 88.88% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main    #6703      +/-   ##
============================================
- Coverage     23.02%   22.95%   -0.07%     
  Complexity      475      475              
============================================
  Files           252      252              
  Lines         12101    12130      +29     
  Branches       2307     2318      +11     
============================================
- Hits           2786     2785       -1     
- Misses         8989     9019      +30     
  Partials        326      326              
Flag Coverage Δ
javascript 14.50% <27.58%> (-0.06%) ⬇️
php 59.30% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2. developing Work in progress bug Feature: Scheduling Anything around scheduling meetings, free-busy, resources, attendees and so on
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Free/Busy (find a time) showing invalid slots
1 participant