mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
MDL-16166 centralised enabling of subsystems, fixed some warnings and general cleanup
This commit is contained in:
parent
3c184e1464
commit
90658eefb0
24 changed files with 84 additions and 48 deletions
|
@ -188,7 +188,7 @@ function portfolio_add_button($callbackclass, $callbackargs, $callbackfile=null,
|
|||
|
||||
global $SESSION, $CFG, $COURSE, $USER;
|
||||
|
||||
if (empty($CFG->portfolioenabled)) {
|
||||
if (empty($CFG->enableportfolios)) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -317,7 +317,7 @@ function portfolio_add_button($callbackclass, $callbackargs, $callbackfile=null,
|
|||
function portfolio_instance_select($instances, $callerformats, $callbackclass, $selectname='instance', $return=false, $returnarray=false) {
|
||||
global $CFG;
|
||||
|
||||
if (empty($CFG->portfolioenabled)) {
|
||||
if (empty($CFG->enableportfolios)) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -4484,7 +4484,7 @@ has_capability('moodle/course:viewhiddenuserfields', $context)) {
|
|||
$output .= '<a href="'.$CFG->wwwroot.'/blog/index.php?userid='.$user->id.'">'.get_string('blogs','blog').'</a><br />';
|
||||
}
|
||||
//link to notes
|
||||
if (has_capability('moodle/notes:manage', $context) || has_capability('moodle/notes:view', $context)) {
|
||||
if (!empty($CFG->enablenotes) and (has_capability('moodle/notes:manage', $context) || has_capability('moodle/notes:view', $context))) {
|
||||
$output .= '<a href="'.$CFG->wwwroot.'/notes/index.php?course=' . $course->id. '&user='.$user->id.'">'.get_string('notes','notes').'</a><br />';
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue