Skip to content

Commit

Permalink
Don't show outcomes at all if it's not enabled.
Browse files Browse the repository at this point in the history
  • Loading branch information
moodler committed Aug 1, 2007
1 parent 1f496de commit 33c3535
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions blocks/admin/block_admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,11 @@ function get_content() {
}

/// Course outcomes
if (has_capability('moodle/course:update', $context) && ($course->id!==SITEID)) {
$this->content->items[]='<a href="'.$CFG->wwwroot.'/grade/edit/outcome/course.php?id='.$this->instance->pageid.'">'.get_string('outcomes', 'grades').'</a>';
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/outcomes.gif" class="icon" alt="" />';
if (!empty($CFG->enableoutcomes)) {
if (has_capability('moodle/course:update', $context) && ($course->id!==SITEID)) {
$this->content->items[]='<a href="'.$CFG->wwwroot.'/grade/edit/outcome/course.php?id='.$this->instance->pageid.'">'.get_string('outcomes', 'grades').'</a>';
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/outcomes.gif" class="icon" alt="" />';
}
}

/// Manage scales
Expand Down

0 comments on commit 33c3535

Please sign in to comment.