This file drives the reset of several courses. It is not tied to a scheduled task.
| Field | Value | |
|---|---|---|
| shortname | Course short name | Mandatory |
| events | 'yes' or 'no' | Mandatory |
| logs | 'yes' or 'no' | Mandatory |
| notes | 'yes' or 'no' | Mandatory |
| grades | one of ('items', 'grades', 'nothing') | Mandatory |
| roles | a list among ('guest', 'admin', 'student', 'teacher', 'editingteacher', …) or 'all' | Mandatory |
| local_roles | whether local role assignments (outside enrolment) must be removed or not. 0 or 1 | Mandatory |
| groups | one of ('members', 'groups', 'nothing') | Mandatory |
| groupings | one of ('all', 'members', 'groups', 'nothing') | Mandatory |
| modules | all: all the modules, otherwise a succession of module names separated by spaces, with the possibility of selecting by exclusion (see example) | Mandatory |
| forum_all | 1 or 0 | Optional |
| forum_subscriptions | 1 or 0 | Optional |
| chat | 1 or 0 | Optional |
| … | 1 or 0 | Optional |
By creating a resetlib.php file at the root of your modules and writing the '$modname'_reset_course_form_definition function returning an array of reset variables, you can make your module compatible with this script. Also remember to complete the '$modname'_reset_course_form_default functions in your module's lib.php.
The last line corresponds to: All modules except the forum and the chat.