moodle/lib/classes
Simey Lameze 5b0282847e MDL-71156 core: machinery to recover orphaned calendar events
The machinery to fix orphaned calendar events that were broken by MDL-67494.

The solution consists of:

1) Upgrade step that checks if this site has executed the problematic upgrade steps and
   if positive, it will schedule a new run for calendar_fix_orphaned_events adhoc task.

2) Adhoc task that will self-spawn calling the recovery machinery, running until
   all the orphaned calendar events are fixed. It also sets the maximum runtime of
   60 seconds. It is also possible to override that number by specifing the desired
   number setting the ->calendareventsmaxseconds in your config.php

3) CLI script that will look for all the calendar events which userids
   where broken by a wrong upgrade step, affecting to Moodle 3.9.5
   and up.

   It performs checks to both:
     a) Detect if the site was affected (ran the wrong upgrade step).
     b) Look for orphaned calendar events, categorising them as:
       - standard: site / category / course / group / user events
       - subscription: events created via subscriptions.
       - action: normal action events, created to show common important dates.
       - override: user and group override events, particular, that some activities support.
       - custom: other events, not being any of the above, common or particular.

   By specifying it (--fix) try to recover as many broken events (missing userid) as
   possible. Standard, subscription, action, override events in core are fully supported but
   override or custom events should be fixed by each plugin as far as there isn't any standard
   API (plugin-wise) to launch a rebuild of the calendar events.

4) Unit tests and helper functions to generate calendar events. We have decided to
   keep the tests simple, testing only true and false and not using data generators because
   the code is purely to recover the calendar events and won't turn into an API or something
   and also due to the urgency of this issue.
   The helpers have been created in calendar/tests/helpers.php since there are no data generators
   for calendar.
2021-04-22 10:28:52 +08:00
..
access MDL-60983 get_user_capability_course: fix buggy edge cases 2017-12-07 18:28:18 +00:00
analytics MDL-67119 core_analytics: Analyse users once per course 2021-02-26 11:50:16 +01:00
antivirus MDL-69522 antivirus: Added ability for scanners to set found message 2020-12-07 14:44:24 +10:00
check MDL-71099 Lib: Move new user_fields class from core to core_user 2021-03-25 13:47:23 +00:00
content/export Merge branch 'MDL-70579' of git://github.com/paulholden/moodle 2021-02-04 09:28:22 +08:00
dataformat MDL-67547 dataformat_pdf: method to convert images to supported format. 2020-05-26 00:54:27 +01:00
dml MDL-68402 accesslib: fix get_with_capability_join logic 2020-05-06 09:18:02 +01:00
event MDL-71011 php80: final private makes no sense, throwing warning 2021-04-12 18:49:38 +02:00
external MDL-69215 output: Correct font awesome for themes 2020-07-16 07:29:22 +08:00
files MDL-69050 lang: Fix variables and methods names in curl_security_helper 2020-09-24 19:41:57 +02:00
form MDL-69166 core_payment: add payment accounts 2020-10-27 14:40:49 +11:00
hub MDL-67753 registration: Enable Push Notifications when site register 2020-05-06 23:20:13 +02:00
local/cli MDL-59594 cli: Introduce cli helpers for graceful exits 2020-01-12 01:20:04 +11:00
lock MDL-69521 core: Move all comments in code from 4.0 to 3.10 2020-09-06 17:00:25 +02:00
log MDL-49291 core: final deprecation of sql_*_reader interfaces 2016-01-18 14:24:34 +08:00
message MDL-70552 core_message: Show popup for teachers when anonymous 2021-02-17 08:42:52 +02:00
navigation/views MDL-70207 core_navigation: Initial backend for primary navigation 2021-04-06 11:45:44 +08:00
oauth2 MDL-70722 oauth2: move Nextcloud methods to service class 2021-03-26 09:20:52 +01:00
output MDL-70316 core: Update the emoji categories in the emoji picker 2021-01-27 13:37:03 +08:00
plugininfo MDL-70766 auth: Add all auth plugin changes to configlog 2021-02-11 11:05:25 +11:00
privacy MDL-59510 core: report oauth2_refresh_token table in core provider 2020-10-05 09:19:29 +08:00
progress MDL-28505 Backup: Asynchronous backup and restore 2019-04-09 00:15:42 +00:00
session Merge branch 'MDL-70424-auth-avoid-changes' of https://github.com/brendanheywood/moodle 2021-03-04 00:27:53 +01:00
task MDL-71156 core: machinery to recover orphaned calendar events 2021-04-22 10:28:52 +08:00
update MDL-66917 admin: validate uploaded plugin version. 2020-04-21 14:35:59 +01:00
upgrade MDL-56917 core_upgrade: Do not use the raw version to check cURL caps. 2016-11-15 21:50:07 +01:00
activity_dates.php MDL-70816 core: Activity date details base class 2021-03-22 16:15:17 +11:00
chart_axis.php MDL-54987 charts: fix style issues 2016-07-25 11:21:31 +01:00
chart_bar.php MDL-55665 core: Add support for stacked bar charts 2016-08-26 13:30:01 +08:00
chart_base.php MDL-68477 libraries: support for Chart.js legend options. 2020-04-23 09:23:21 +08:00
chart_line.php MDL-54987 charts: fix style issues 2016-07-25 11:21:31 +01:00
chart_pie.php MDL-55710 core: Add support for doughnut charts 2016-08-26 13:30:02 +08:00
chart_series.php MDL-68386 libraries: Enhancement for Area Charts support with chart.js. 2020-04-17 09:12:41 +12:00
collator.php
component.php MDL-65743 lib: add XMPPHP namespace and update calls 2020-10-05 13:37:51 +08:00
content.php MDL-69559 course: Add capability and access checks for course download 2020-10-26 10:00:47 +08:00
cssparser.php MDL-55071 psr4: Use psr4 classloader for scss, rtlcss and cssparser 2016-09-23 10:57:35 +01:00
dataformat.php MDL-55971 dataformat: method to write exports to file storage. 2020-08-25 17:28:55 +01:00
date.php MDL-67943 core: Update timezone list in core_date 2020-08-17 09:06:30 +08:00
encryption.php MDL-65818 Security: Encryption API and admin setting for secure data 2020-12-04 14:41:21 +00:00
filetypes.php MDL-61215 core_files: add new optimised_image group 2020-08-14 17:06:23 +02:00
geopattern.php MDL-61657 block_myoverview: whitespace and css-style fixes 2018-04-23 23:35:17 +02:00
grades_external.php MDL-71031 webservices: Extended gradecategory creation API 2021-04-18 11:52:07 +02:00
grading_external.php
invalid_persistent_exception.php MDL-57273 core: Migrating persistent from core_competency into core 2017-01-20 12:56:18 +08:00
ip_utils.php MDL-66732 core: improve detection of non-public sites. 2020-04-15 21:54:29 +01:00
minify.php MDL-53695 minify: switch to MatthiasMullie\Minify 2016-10-10 13:17:04 +01:00
notification.php MDL-62678 core: Improve efficiency of notifications and avoid ajax call 2020-09-30 13:55:30 +10:00
persistent.php MDL-65096 docs: Use static return type in persistent 2019-03-18 10:30:48 +00:00
php_time_limit.php
plugin_manager.php MDL-69166 core_payment: Renamed plugintype name from pg to paygw 2020-10-27 15:34:55 +11:00
qrcode.php MDL-65547 qr: Wrapper for core_qrcode 2020-05-08 10:26:45 +02:00
requirejs.php MDL-66502 javascript: Remove extension from AMD module names 2019-09-09 16:25:17 +08:00
rtlcss.php MDL-55071 psr4: Use psr4 classloader for scss, rtlcss and cssparser 2016-09-23 10:57:35 +01:00
scss.php MDL-65761 lib: Update scssphp to 1.0.0 2019-07-16 09:16:44 +08:00
shutdown_manager.php MDL-70920 core: prevent calls to call_user_fun_array() with assoc array 2021-02-21 22:22:21 +01:00
string_manager.php
string_manager_install.php
string_manager_standard.php MDL-69788 lang: fallback to all translations if misconfigured. 2020-10-16 14:33:39 +01:00
text.php MDL-66965 core: php74 curly 2 square braces changes 2019-10-25 17:41:10 +02:00
user.php MDL-71099 Lib: Move new user_fields class from core to core_user 2021-03-25 13:47:23 +00:00
useragent.php MDL-66972 Files API: Add Streaming file mime type support 2019-12-08 06:10:01 +11:00
userfeedback.php Merge branch 'MDL-68991-master' of git://github.com/rezaies/moodle 2020-06-11 12:27:16 +08:00
uuid.php MDL-61038 setuplib: Fixed PECL UUID extension support 2019-06-09 23:24:26 +02:00