Merge branch 'MDL-48074_not_in_group' of git://github.com/davosmith/moodle
This commit is contained in:
+7
-2
@@ -280,8 +280,13 @@ class course_enrolment_manager {
|
||||
|
||||
// Group condition.
|
||||
if ($this->groupfilter) {
|
||||
$sql .= " AND gm.groupid = :groupid";
|
||||
$params['groupid'] = $this->groupfilter;
|
||||
if ($this->groupfilter < 0) {
|
||||
// Show users who are not in any group.
|
||||
$sql .= " AND gm.groupid IS NULL";
|
||||
} else {
|
||||
$sql .= " AND gm.groupid = :groupid";
|
||||
$params['groupid'] = $this->groupfilter;
|
||||
}
|
||||
}
|
||||
|
||||
// Status condition.
|
||||
|
||||
@@ -167,6 +167,7 @@ class enrol_users_filter_form extends moodleform {
|
||||
// Filter by group.
|
||||
$allgroups = $manager->get_all_groups();
|
||||
$groupsmenu[0] = get_string('allparticipants');
|
||||
$groupsmenu[-1] = get_string('nogroup', 'enrol');
|
||||
foreach($allgroups as $gid => $unused) {
|
||||
$groupsmenu[$gid] = $allgroups[$gid]->name;
|
||||
}
|
||||
|
||||
@@ -94,6 +94,7 @@ $string['manageinstance'] = 'Manage';
|
||||
$string['migratetomanual'] = 'Migrate to manual enrolments';
|
||||
$string['nochange'] = 'No change';
|
||||
$string['noexistingparticipants'] = 'No existing participants';
|
||||
$string['nogroup'] = 'No group';
|
||||
$string['noguestaccess'] = 'Guests can not access this course, please try to log in.';
|
||||
$string['none'] = 'None';
|
||||
$string['notenrollable'] = 'You can not enrol yourself in this course.';
|
||||
|
||||
Reference in New Issue
Block a user