FreePBX / issue-tracker

The unified FreePBX issue tracker.
https://www.freepbx.org
GNU General Public License v3.0
5 stars 1 forks source link

[bug]: Issues with the Calendar Module and iCal links to google calendar. #108

Open digiaust opened 2 months ago

digiaust commented 2 months ago

FreePBX Version

FreePBX 15

Issue Description

Hi there, thank you for all your work on this project.

Found a few issues with Calendaring when linking to a Google calendar and creating repeating events.

  1. Events that repeat by more than every 2 weeks just repeat weekly no matter the range. (Tested every 2 weeks to every 8 weeks)
  2. Week-long events that have time set at the same start and end time (but different days) will not show times and will occur at midnight (and not display times) instead of set times.
  3. Events that are set to reoccur more than every 30 days (daily) (as a workaround to the reoccur weekly issue) will not reset BLF status until feature code is toggled. (Calendar and call flow operate properly but BLF keys are stuck and do not switch to unmatched despite calendar reflecting event has ended)

Issue 1: Events that repeat weekly, more than every 2 weeks, just repeat weekly.

Issue: When creating an event that needs to repeat every 2+ weeks in Google Calendar, events will just be repeated weekly.

Reproducibility: 98%.

Expected: Events should repeat at the specified intervals, such as every 3 weeks, without reverting to weekly repetition.

Actual: Events set to repeat every 2+ weeks revert to repeating weekly.

Steps to Reproduce:

  1. Link a Google Calendar to FPBX via Remote iCal.
  2. Create an event and set it to repeat every 3 weeks.
  3. Observe that the event repeats weekly instead of every 3 weeks.

Issue 2: Multi-day events that start and end at the same time do not show the time in Calendar/Event View and occur at Midnight instead of set time.

Issue: Week-long events with the same start and end time across multiple days fail to display times and default to occurring at midnight.

Reproducibility: 90%.

Expected: Multi-day events should display and occur at the set times, regardless of the event duration.

Actual: Events are scheduled at midnight and do not display set times in the calendar.

Steps to Reproduce:

  1. Link a Google Calendar to FPBX via Remote iCal.
  2. Create a multi-day event, setting the start and end times to be the same.
  3. Observe that the event time is not displayed and defaults to midnight.

Issue 3: Events that are set to reoccur more than every 30 days properly reoccur in the calendar and in regards to the call flow but BLF hints remain stuck.

Issue: Events set to recur every 30+ days display correctly in the calendar and affect call flow as expected, but BLF hints do not reset post-event without toggling the feature code.

Reproducibility: 95%.

Expected: BLF status should automatically update to reflect the end of an event.

Actual: BLF keys remain stuck and do not switch to "unmatched" status despite the calendar reflecting that the event has ended.

Steps to Reproduce:

  1. Link a Google Calendar to FPBX via Remote iCal.
  2. Set an event to reoccur every 31 days.
  3. After the event, observe that the BLF status does not reset unless the feature code is toggled manually.

Operating Environment

All issues affect FPBX version 15.0.37.4 (Asterisk Version: 16.30.0) and 16.0.40.7 (Asterisk Version:16.30.0)

Calendar 15.0.10 Stable

+---------------------+------------+---------+------------+-----------+ | Module | Version | Status | License | Signature | +---------------------+------------+---------+------------+-----------+ | accountcodepreserve | 13.0.2.2 | Enabled | GPLv2 | Sangoma | | amd | 15.0.3 | Enabled | GPLv3+ | Sangoma | | announcement | 15.0.3.13 | Enabled | GPLv3+ | Sangoma | | api | 15.0.11 | Enabled | AGPLv3+ | Sangoma | | arimanager | 15.0.3.20 | Enabled | GPLv3+ | Sangoma | | asterisk-cli | 14.0.4 | Enabled | GPLv3+ | Sangoma | | asteriskinfo | 15.0.14 | Enabled | GPLv3+ | Sangoma | | backup | 15.0.26 | Enabled | GPLv3+ | Sangoma | | blacklist | 15.0.4 | Enabled | GPLv3+ | Sangoma | | builtin | | Enabled | | Unsigned | | bulkhandler | 15.0.4 | Enabled | GPLv3+ | Sangoma | | calendar | 15.0.10 | Enabled | GPLv3+ | Sangoma | | callback | 15.0.12 | Enabled | GPLv3+ | Sangoma | | callforward | 15.0.16 | Enabled | AGPLv3+ | Sangoma | | callrecording | 15.0.7.29 | Enabled | AGPLv3+ | Sangoma | | callwaiting | 15.0.4.6 | Enabled | GPLv3+ | Sangoma | | campon | 13.0.4.1 | Enabled | GPLv3+ | Sangoma | | cdr | 15.0.24.6 | Enabled | GPLv3+ | Sangoma | | cel | 15.0.17 | Enabled | GPLv3+ | Sangoma | | certman | 15.0.49 | Enabled | AGPLv3+ | Sangoma | | cidlookup | 15.0.27 | Enabled | GPLv3+ | Sangoma | | conferences | 15.0.7.11 | Enabled | GPLv3+ | Sangoma | | configedit | 13.0.7.3 | Enabled | AGPLv3+ | Sangoma | | contactmanager | 15.0.13 | Enabled | GPLv3+ | Sangoma | | core | 15.0.22.34 | Enabled | GPLv3+ | Sangoma | | customappsreg | 15.0.14 | Enabled | GPLv3+ | Sangoma | | dashboard | 15.0.18 | Enabled | AGPLv3+ | Sangoma | | daynight | 15.0.12 | Enabled | GPLv3+ | Sangoma | | directory | 15.0.19 | Enabled | GPLv3+ | Sangoma | | disa | 15.0.4.9 | Enabled | AGPLv3+ | Sangoma | | donotdisturb | 15.0.10 | Enabled | GPLv3+ | Sangoma | | extensionsettings | 13.0.4 | Enabled | GPLv3+ | Sangoma | | fax | 15.0.22 | Enabled | GPLv3+ | Sangoma | | featurecodeadmin | 13.0.6.11 | Enabled | GPLv3+ | Sangoma | | filestore | 15.0.9 | Enabled | AGPLv3 | Sangoma | | findmefollow | 15.0.37 | Enabled | GPLv3+ | Sangoma | | firewall | 15.0.43 | Enabled | AGPLv3+ | Sangoma | | framework | 15.0.37.4 | Enabled | GPLv2+ | Sangoma | | fw_langpacks | 14.0.1 | Enabled | GPLv3+ | Sangoma | | hotelwakeup | 15.0.5.5 | Enabled | GPLv2 | Sangoma | | infoservices | 15.0.3 | Enabled | GPLv2+ | Sangoma | | irc | 13.0.1 | Enabled | GPLv3+ | Sangoma | | ivr | 15.0.30 | Enabled | GPLv3+ | Sangoma | | languages | 15.0.13 | Enabled | GPLv3+ | Sangoma | | logfiles | 15.0.15 | Enabled | GPLv3+ | Sangoma | | manager | 15.0.23 | Enabled | GPLv2+ | Sangoma | | miscapps | 15.0.10 | Enabled | GPLv3+ | Sangoma | | miscdests | 15.0.2.12 | Enabled | GPLv3+ | Sangoma | | music | 15.0.22 | Enabled | GPLv3+ | Sangoma | | outroutemsg | 15.0.9 | Enabled | GPLv3+ | Sangoma | | paging | 15.0.4.35 | Enabled | GPLv3+ | Sangoma | | pagingpro | 15.0.2 | Enabled | Commercial | Sangoma | | parking | 15.0.15.4 | Enabled | GPLv3+ | Sangoma | | pbdirectory | 2.11.0.6 | Enabled | GPLv3+ | Sangoma | | phonebook | 15.0.12 | Enabled | GPLv3+ | Sangoma | | phpinfo | 13.0.2 | Enabled | GPLv2+ | Sangoma | | pinsets | 15.0.1.15 | Enabled | GPLv3+ | Sangoma | | pm2 | 15.0.10 | Enabled | AGPLv3+ | Sangoma | | presencestate | 15.0.11 | Enabled | GPLv3+ | Sangoma | | printextensions | 13.0.3.4 | Enabled | GPLv3+ | Sangoma | | queueprio | 15.0.10 | Enabled | GPLv3+ | Sangoma | | queues | 15.0.39 | Enabled | GPLv2+ | Sangoma | | queuestats | 15.0.14 | Enabled | Commercial | Sangoma | | recordings | 15.0.6 | Enabled | GPLv3+ | Sangoma | | ringgroups | 15.0.11.17 | Enabled | GPLv3+ | Sangoma | | setcid | 15.0.9 | Enabled | GPLv3+ | Sangoma | | sipsettings | 15.0.11 | Enabled | AGPLv3+ | Sangoma | | sms | 15.0.37 | Enabled | Commercial | Sangoma | | soundlang | 15.0.5.10 | Enabled | GPLv3+ | Sangoma | | speeddial | 2.11.0.4 | Enabled | GPLv3+ | Sangoma | | superfecta | 15.0.5 | Enabled | GPLv2+ | Sangoma | | sysadmin | 15.0.33.14 | Enabled | Commercial | Sangoma | | timeconditions | 15.0.15.11 | Enabled | GPLv3+ | Sangoma | | tts | 15.0.12 | Enabled | GPLv3+ | Sangoma | | ttsengines | 15.0.4.7 | Enabled | AGPLv3 | Sangoma | | ucp | 15.0.15 | Enabled | AGPLv3+ | Sangoma | | userman | 15.0.69.19 | Enabled | AGPLv3+ | Sangoma | | vmblast | 15.0.11.8 | Enabled | GPLv3+ | Sangoma | | voicemail | 15.0.32 | Enabled | GPLv3+ | Sangoma | | weakpasswords | 13.0.2 | Enabled | GPLv3+ | Sangoma | | xmpp | 15.0.6.12 | Enabled | AGPLv3 | Sangoma | Screenshot 2024-04-15 235152 Screenshot 2024-04-15 180726 Screenshot 2024-04-15 174322 Screenshot 2024-04-15 174313 Screenshot 2024-04-15 174253 Screenshot 2024-04-15 174241 Screenshot 2024-04-15 171838

Relevant log output

No response

digiaust commented 2 months ago

Regarding issue 3: Events set to repeat every more than 30 days BLF hints remain stuck and do not update:

It might have something to do with FPBX inability to repeat an event more than every 30 days in the calendar module:

Google Calendar with event set to repeat daily, but more than every 30 days: image

Same Calendar reflected in FPBX shared via iCal link. (Notice repeating days are not shown): image (The calendar events are still accurately reflected in the calendar. The time condition still works to route call flows properly, but the BLF hints do not update.

Notice however, a repeat every X days event under 30 days reflects accurately and BLF hints function normally. image image

digiaust commented 2 months ago

Regarding Issue 2: Multi-day Events that have the same start and end times do not reflect the set time and revert to midnight (00:00):

Google Calendar with multi-day event that starts at 7:00am and ends at 7:00am two days later: image

Same Calendar reflected in FPBX: (Notice only the dates are set, no time) image

This time condition will toggle at midnight instead of the set time in the calendar.

Notice that when changing the time 1 minute apart, FPBX then recognizes the set times.

Google Calendar event starting at 7am Monday and ending 7:01am Wednesday image

Notice now in FPBX Cal the time is reflected: image

image

Changing the time back to 7a-7a reverts it to the bug where the time reverts to midnight

digiaust commented 2 months ago

Regarding Issue 1: Events repeated more than every 1 week are just repeated weekly

I think resolving this issue will resolve Issue 3 as the correct way to repeat an event more than X+ days is to do it weekly. Currently however when trying to repeat an event more than 1 week, (eg every 3 weeks) the event will just duplicate weekly.

See original event in Google Calendar: This event is set to repeat every 2 weeks (every other week) image

See event in FPBX repeating every week: image

This despite the UI showing it is a bi weekly event. image

The time condition and BLF will be activated every week as displayed on the calendar despite being an every other week event.

This remains true no matter how many weeks between the event should repeat.

Every 4 weeks: image

Every 4 weeks on calendar in FPBX: image

Every 4 weeks in event in FPBX: image

It however doesn't seem to affect monthly or yearly events: image

May: image

June: image

July: image