Files
moodle/course/report/completion/mod.php
T
Martin Dougiamas 2be4d090c0 course completion MDL-2631 Course completion feature - Thanks to Aaron Barnes and Catalyst IT for this significant contribution. It is now officially possible to finish a course!
Even though I've tweaked this and done some polishing, there is still plenty to do on it now in HEAD, mostly to do with UI, usability and strings, so we'll keep working on it.  Aaron already has a number of improvements to add to it.
2010-04-30 03:06:22 +00:00

16 lines
555 B
PHP

<?php //$Id$
if (!defined('MOODLE_INTERNAL')) {
die('Direct access to this script is forbidden.'); // It must be included from a Moodle page
}
if (has_capability('coursereport/completion:view', $context)) {
$completion = new completion_info($course);
if ($completion->is_enabled()) {
echo '<p>';
echo '<a href="'.$CFG->wwwroot.'/course/report/completion/index.php?course='.$course->id.'">'.get_string('coursecompletionreport','completion').'</a>';
echo '</p>';
}
}
?>