mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 22:08:20 +01:00
MDL-29030 minor completion report cleanup
This commit is contained in:
parent
13fdaaacc3
commit
764607014d
@ -1,27 +1,28 @@
|
||||
<?php
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
// //
|
||||
// NOTICE OF COPYRIGHT //
|
||||
// //
|
||||
// Moodle - Modular Object-Oriented Dynamic Learning Environment //
|
||||
// http://moodle.com //
|
||||
// //
|
||||
// Copyright (C) 1999 onwards Martin Dougiamas http://moodle.com //
|
||||
// //
|
||||
// This program is free software; you can redistribute it and/or modify //
|
||||
// it under the terms of the GNU General Public License as published by //
|
||||
// the Free Software Foundation; either version 2 of the License, or //
|
||||
// (at your option) any later version. //
|
||||
// //
|
||||
// This program is distributed in the hope that it will be useful, //
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of //
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
|
||||
// GNU General Public License for more details: //
|
||||
// //
|
||||
// http://www.gnu.org/copyleft/gpl.html //
|
||||
// //
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
/**
|
||||
* Capabilities
|
||||
*
|
||||
* @package report
|
||||
* @subpackage completion
|
||||
* @copyright 2009 Catalyst IT Ltd
|
||||
* @author Aaron Barnes <aaronb@catalyst.net.nz>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
$capabilities = array(
|
||||
|
||||
|
@ -27,7 +27,7 @@ defined('MOODLE_INTERNAL') || die;
|
||||
|
||||
function xmldb_report_completion_install() {
|
||||
// this is a hack which is needed for cleanup of original coursereport_completion stuff
|
||||
unset_all_config_for_plugin('coursereport_online');
|
||||
capabilities_cleanup('coursereport_online');
|
||||
unset_all_config_for_plugin('coursereport_completion');
|
||||
capabilities_cleanup('coursereport_completion');
|
||||
}
|
||||
|
||||
|
@ -1,5 +1,4 @@
|
||||
<?php
|
||||
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
@ -15,16 +14,17 @@
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
|
||||
/**
|
||||
* Course completion progress report
|
||||
*
|
||||
* @package moodlecore
|
||||
* @package report
|
||||
* @subpackage completion
|
||||
* @copyright 2009 Catalyst IT Ltd
|
||||
* @author Aaron Barnes <aaronb@catalyst.net.nz>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
require_once('../../config.php');
|
||||
|
||||
require('../../config.php');
|
||||
require_once($CFG->libdir.'/completionlib.php');
|
||||
|
||||
/**
|
||||
@ -33,7 +33,7 @@ require_once($CFG->libdir.'/completionlib.php');
|
||||
define('COMPLETION_REPORT_PAGE', 25);
|
||||
define('COMPLETION_REPORT_COL_TITLES', true);
|
||||
|
||||
/**
|
||||
/*
|
||||
* Setup page, check permissions
|
||||
*/
|
||||
|
||||
@ -139,7 +139,7 @@ if (!$csv) {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
/*
|
||||
* Setup page header
|
||||
*/
|
||||
if ($csv) {
|
||||
@ -314,7 +314,7 @@ if($total > COMPLETION_REPORT_PAGE) {
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
/*
|
||||
* Draw table header
|
||||
*/
|
||||
|
||||
|
@ -1,4 +1,28 @@
|
||||
<?php
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Lang strings
|
||||
*
|
||||
* @package report
|
||||
* @subpackage completion
|
||||
* @copyright 2009 Catalyst IT Ltd
|
||||
* @author Aaron Barnes <aaronb@catalyst.net.nz>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
$string['completion:view'] = 'View course completion report';
|
||||
$string['completiondate'] = 'Completion date';
|
||||
|
@ -1,5 +1,4 @@
|
||||
<?php
|
||||
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
@ -16,14 +15,15 @@
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* This file contains functions used by the progress report
|
||||
* Version details.
|
||||
*
|
||||
* @package course-report
|
||||
* @package report
|
||||
* @subpackage completion
|
||||
* @copyright 2009 Sam Hemelryk
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
require_once($CFG->libdir.'/completionlib.php');
|
||||
defined('MOODLE_INTERNAL') || die;
|
||||
|
||||
/**
|
||||
* This function extends the navigation with the report items
|
||||
@ -35,6 +35,8 @@ require_once($CFG->libdir.'/completionlib.php');
|
||||
function report_completion_extend_navigation_course($navigation, $course, $context) {
|
||||
global $CFG, $OUTPUT;
|
||||
|
||||
require_once($CFG->libdir.'/completionlib.php');
|
||||
|
||||
if (has_capability('report/completion:view', $context)) {
|
||||
$completion = new completion_info($course);
|
||||
if ($completion->is_enabled() && $completion->has_criteria()) {
|
||||
|
@ -15,11 +15,12 @@
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Version details.
|
||||
* Version details
|
||||
*
|
||||
* @package report
|
||||
* @subpackage completion
|
||||
* @copyright 1999 onwards Martin Dougiamas (http://dougiamas.com)
|
||||
* @copyright 2009 Catalyst IT Ltd
|
||||
* @author Aaron Barnes <aaronb@catalyst.net.nz>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user