Differences Between: [Versions 400 and 401] [Versions 400 and 402] [Versions 400 and 403]
Local stuff for meta course enrolment plugin.
Copyright: | 2010 Petr Skoda {@link http://skodak.org} |
License: | http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
File Size: | 665 lines (31 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
enrol_meta_handler:: (5 methods):
sync_course_instances()
sync_with_parent_course()
user_not_supposed_to_be_here()
enrol_meta_sync()
enrol_meta_create_new_group()
Class: enrol_meta_handler - X-Ref
Event handler for meta enrolment plugin.sync_course_instances($courseid, $userid) X-Ref |
Synchronise meta enrolments of this user in this course return: void param: int $courseid param: int $userid |
sync_with_parent_course(stdClass $instance, $userid) X-Ref |
Synchronise user enrolments in given instance as fast as possible. All roles are removed if the meta plugin disabled. return: void param: stdClass $instance param: int $userid |
user_not_supposed_to_be_here($instance, $ue, context_course $context, $plugin) X-Ref |
Deal with users that are not supposed to be enrolled via this instance return: void param: stdClass $instance param: stdClass $ue param: context_course $context param: enrol_meta $plugin |
enrol_meta_sync($courseid = NULL, $verbose = false) X-Ref |
Sync all meta course links. return: int 0 means ok, 1 means error, 2 means plugin disabled param: int $courseid one course, empty mean all param: bool $verbose verbose CLI output |
enrol_meta_create_new_group($courseid, $linkedcourseid) X-Ref |
Create a new group with the course's name. return: int $groupid Group ID for this cohort. param: int $courseid param: int $linkedcourseid |