Behat tests for lang import. To run these tests you must define the
TOOL_LANGIMPORT_REMOTE_TESTS constant - because they rely on the
download.moodle.org infrastructure.
When working against external services it can be advantageous to not
have automated tasks all hit the service at the exact same time from
many different installations.
This change allows the use of 'R' in hour/minute fields of the scheduled
task definition so a task will be installed with a 'random' hour/minute
value for these sort of occasions.
Note that the task will be installed in the database with a defined
time, this simply randomises the time chosen when loading from the
definiton.
When working against external services it can be advantageous to not
have automated tasks all hit the service at the exact same time from
many different installations.
This change allows the use of 'R' in hour/minute fields of the scheduled
task definition so a task will be installed with a 'random' hour/minute
value for these sort of occasions.
Note that the task will be installed in the database with a defined
time, this simply randomises the time chosen when loading from the
definiton.
Added property 'visible' for cohorts. Unsetting it hides the cohort from users in the course.
AMOS BEGIN
CPY [visible,core_moodle],[visible,core_cohort]
AMOS END
Cohort capabilities are defined in lang/en/roles.php, remove(rename) the capability-styled strings
AMOS BEGIN
CPY [cohort:assign,core_assign],[assigncohorts,core_assign]
AMOS END
This part of the code is changing an index on the course_sections table to be unique, for this to happen in the upgrade script the index must be deleted and then the new version added.
Before this change the following was being done:
* The index is removed
* A query to delete records that were not unique on this index is performed
* The unique version of the index is added
After this change the following happens:
* A query to delete records that were not unique on this index is performed
* The index is removed
* The unique version of the index is added
When the original index is present the query uses it, which greatly improves the execution plan.
Before the change an upgrade on a site with around 387967 course_section records the upgrade would be stuck on the delete query for many hours, after the change the time can be measured in minutes.
This is a basic implementation of the actual content generation in the workshop
generator. Note the we do not generate actual grading form data (which is what
the grading strategy plugins would do), just their results.
This is built upon original work by Michael Hughes. We now have separate
settings for deleting workshop submissions, assessments and for resetting the
workshop phase.
The methods workshop::delete_submission() and workshop::delete_assessment() did
not delete files (embedded and attachments) associated with the given
submission or assessment. This is fixed now.
Additionally, the delete_assessment() method now cleans-up records from the
table workshop_grades, too. This internal workshop API still does not give
workshop subplugins a chance to clean up their data, should they store them in
their own tables instead of the workshop_grades one. This should be improved in
the future yet.
This is unrelated to the issue but was spotted while testing it. The order of
format_text() and file_rewrite_pluginfile_urls() was incorrect and threw
debugging message. Fixed now.
Not related to the issue itself but spotted while working on the
workshop reset feature. Assigning copyleft holder to Petr as the
original author of the file.
While doing this code clean-up, I noticed that the question bank pop-up was
only showing the question name, whereas it should have been showing the
question name and the start of the question text, so I fixed that.