Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-46084

Changing site Timezone affects All-day Calendar events imported from Google, incorrectly

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.6.3, 2.7.1
    • Fix Version/s: 2.7.3
    • Component/s: Calendar
    • Testing Instructions:
      Hide

      Testing requires access to a Google Calendar

      Test #1 verify that imports work correctly when the server in on your local timezone
      1 Ensure the timezone on Moodle is set to your local time zone (ex London)
      2 Create an all-day calendar event in the Google Calendar
      3 Create a timed calendar event in the Google Calendar
      4 navigate to the Import Calendar page on your local moodle install (http://localhost/moodle/calendar/managesubscriptions.php)
      5 Add your Google calendar using the Ical private URL (Available under Calendar Details on the Google calendar page)
      6 Import your google calendar. and verify both entries imported without error.
      7 Verify that the all-day calendar event correctly shows under one day in Moodle, starting at 00:00 (without a duration)
      8 Verify that the timed event displays correctly.
      9 Remove the Google calendar subscription

      Test #2 verify that imports work correctly when the server is in another timezone
      1 Set the timezone on Moodle to UTC
      2 navigate to the Import Calendar page on your local moodle install (http://localhost/moodle/calendar/managesubscriptions.php)
      3 Add your Google calendar using the Ical private URL (used above)
      4 Import your google calendar. and verify both entries imported without error.
      5 Verify that the all-day calendar event correctly imports and is shown on a single day (without a duration) adjusted for UTC
      6 Verify that the timed event displays with the start time correctly adjusted for UTC

      Show
      Testing requires access to a Google Calendar Test #1 verify that imports work correctly when the server in on your local timezone 1 Ensure the timezone on Moodle is set to your local time zone (ex London) 2 Create an all-day calendar event in the Google Calendar 3 Create a timed calendar event in the Google Calendar 4 navigate to the Import Calendar page on your local moodle install ( http://localhost/moodle/calendar/managesubscriptions.php ) 5 Add your Google calendar using the Ical private URL (Available under Calendar Details on the Google calendar page) 6 Import your google calendar. and verify both entries imported without error. 7 Verify that the all-day calendar event correctly shows under one day in Moodle, starting at 00:00 (without a duration) 8 Verify that the timed event displays correctly. 9 Remove the Google calendar subscription Test #2 verify that imports work correctly when the server is in another timezone 1 Set the timezone on Moodle to UTC 2 navigate to the Import Calendar page on your local moodle install ( http://localhost/moodle/calendar/managesubscriptions.php ) 3 Add your Google calendar using the Ical private URL (used above) 4 Import your google calendar. and verify both entries imported without error. 5 Verify that the all-day calendar event correctly imports and is shown on a single day (without a duration) adjusted for UTC 6 Verify that the timed event displays with the start time correctly adjusted for UTC
    • Affected Branches:
      MOODLE_26_STABLE, MOODLE_27_STABLE
    • Fixed Branches:
      MOODLE_27_STABLE
    • Pull Master Branch:
      MDL-46084-master

      Description

      If the timezone for a site is set to (for example) UTC and you add an All Day event to Google Calendar, this correctly shows in moodle as 00:00 -> 00:00, thus spanning over one day.

      However, if you then change the timezone to Europe/London (for example), the All Day event gets moved to 01:00->01:00, thus spanning over two days.

      This is correct for normal timed events, you'd expect this to happen. But not for all day events. All day events should not have their time changed. All day = All day, regardless of the timezone.

      Steps to reproduce:

      1. Ensure timezone on Moodle is set to UTC
      2. Ensure Google Calendar is sync'd with Moodle Calendar & Google Timezone is GMT (London).
      3. Create an all-day calendar event in Google
      4. Create a timed calendar event in Google
      5. Ensure all-day calendar event correctly shows under one day in Moodle, between 00:00 and 00:00.
      6. Ensure timed calendar event displays the time set in Google, minus one hour (due to timezone)
      7. Change timezone from UTC to Europe/London
      8. Timed calendar event in Moodle should now read the same time as Google calendar.
      9. All-day event in Moodle now reads 01:00 -> 01:00, spanning over two days and not one.

      Need more testing done to see if Google Calendar is needed to replicate

        Attachments

          Activity

            People

            • Votes:
              3 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Fix Release Date:
                10/Nov/14