Merge branch 'MDL-45172_block' of https://github.com/andyjdavis/moodle

This commit is contained in:
Dan Poltawski 2014-04-23 16:40:22 +08:00
commit d7ef1ac747

View File

@ -234,7 +234,6 @@ class block_completionstatus extends block_base {
// Display link to detailed view.
$details = new moodle_url('/blocks/completionstatus/details.php', array('course' => $course->id));
$this->content->footer = html_writer::empty_tag('br');
$this->content->footer = html_writer::link($details, get_string('moredetails', 'completion'));
} else {
// If user is not enrolled, show error.
@ -243,6 +242,9 @@ class block_completionstatus extends block_base {
if (has_capability('report/completion:view', $context)) {
$report = new moodle_url('/report/completion/index.php', array('course' => $course->id));
if (empty($this->content->footer)) {
$this->content->footer = '';
}
$this->content->footer .= html_writer::empty_tag('br');
$this->content->footer .= html_writer::link($report, get_string('viewcoursereport', 'completion'));
}