More restrictions on enrol/unenrol of meta courses. Thanks to Bug #4057

Merged from MOODLE_15_STABLE
This commit is contained in:
patrickslee
2005-11-15 21:55:13 +00:00
parent 84d8c4086e
commit 9edf8e04e5
3 changed files with 4 additions and 4 deletions
+1 -1
View File
@@ -200,7 +200,7 @@ class block_admin extends block_list {
$this->content->items[]='<a href="'.$CFG->changepassword.'">'.get_string('changepassword').'</a>';
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" height="16" width="16" alt="" />';
}
if ($CFG->allowunenroll) {
if ($CFG->allowunenroll && !$course->metacourse) {
$this->content->items[]='<a href="unenrol.php?id='.$this->instance->pageid.'">'.get_string('unenrolme', '', $course->shortname).'</a>';
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" height="16" width="16" alt="" />';
}