- Fields added to format_legacy as default course format options;
- Upgrade script copies fields values from table course to course_format_options;
- Fields removed from table course;
- Fields removed from edit course form;
- Since front-page course has a 'numsections' setting, format_site defines it as it's option;
- Removed accessing those fields in core code unless we know that format supports them and in this
case instead of $course = $DB->get_record('course'); we use:
$course = course_get_format($courseorid)->get_course(); This way all format-specific options
are added to the $course object
This reduces the period of time that some of the unit tests
for calculate_next_automated_backup() are failing right now
(from 1week to just some hours around the DST changes).
Note it's not the final solution because they will still fail
when New_York or Brussels DST changes are about to happen, but
to get this completely fixed we'll need to wait to switch from
current custom TZ/DST support to PHP built-in one.
This patch includes following changes and new features:
* Group sync in enrol_cohort plugin.
* Option for editing of role in existing cohort sync instance.
* Group memberships are now restored after enrolments.
* New enrol method for restore of protected group membership.
* New component callback 'restore_group_member' for restore of general plugin group membership.
* New component callback 'restore_role_assignment' for restore of general plugin role assignments.
* Implemented group membership protection in enrolment UI.
* Other minor fixes and cleanup.
Notes:
* The YUI base enrolment page is not reimplemented yet - see MDL-35618.
On backup, contents are cleaned to be safe utf8. That was leading to
some matching problems on restore against not cleaned DB contents (for
already existing questions). This commit adds one fallback method to
perform the match against cleaned DB contents.
Includes option to convert all enrolments to enrol_manual instances, support for mapping of custom fields and fixes for several other problems. This does not include support for custom enrol tables, it will be addressed in another issue.
An activity module might want to use question_usages in different ways.
We should suppport this, because it lets people make interesting
activities.
At the moment, the backup and restore code does not support this,
because it uses fixed element names for the question_usage element and
its children. This fix changes things so that a prefix can be appended
to all the element names.