|
Moodle
2.2.1
http://www.collinsharper.com
|
Go to the source code of this file.
Data Structures | |
| class | enrol_cohort_handler |
Namespaces | |
| namespace | enrol |
Functions | |
| enrol_cohort_sync ($courseid=NULL) | |
| enrol_cohort_enrol_all_users (course_enrolment_manager $manager, $cohortid, $roleid) | |
| enrol_cohort_get_cohorts (course_enrolment_manager $manager) | |
| enrol_cohort_can_view_cohort ($cohortid) | |
| enrol_cohort_search_cohorts (course_enrolment_manager $manager, $offset=0, $limit=25, $search= '') | |
| enrol_cohort_can_view_cohort | ( | $ | cohortid | ) |
Check if cohort exists and user is allowed to enrol it
moodle_database $DB
| int | $cohortid | Cohort ID |
Definition at line 288 of file locallib.php.

| enrol_cohort_enrol_all_users | ( | course_enrolment_manager $ | manager, |
| $ | cohortid, | ||
| $ | roleid | ||
| ) |
Enrols all of the users in a cohort through a manual plugin instance.
In order for this to succeed the course must contain a valid manual enrolment plugin instance that the user has permission to enrol users through.
moodle_database $DB
| course_enrolment_manager | $manager | |
| int | $cohortid | |
| int | $roleid |
Definition at line 205 of file locallib.php.

| enrol_cohort_get_cohorts | ( | course_enrolment_manager $ | manager | ) |
Gets all the cohorts the user is able to view.
moodle_database $DB
| course_enrolment_manager | $manager |
Definition at line 248 of file locallib.php.

| enrol_cohort_search_cohorts | ( | course_enrolment_manager $ | manager, |
| $ | offset = 0, |
||
| $ | limit = 25, |
||
| $ | search = '' |
||
| ) |
Gets cohorts the user is able to view.
moodle_database $DB
| course_enrolment_manager | $manager | |
| int | $offset | limit output from |
| int | $limit | items to output per load |
| string | $search | search string |
Definition at line 310 of file locallib.php.

| enrol_cohort_sync | ( | $ | courseid = NULL | ) |
Sync all cohort course links.
| int | $courseid | one course, empty mean all |
Definition at line 100 of file locallib.php.

