'coursecreator' => CAP_ALLOW,
'admin' => CAP_ALLOW
)
+ ),
+
+ 'moodle/site:doclinks' => array(
+ 'captype' => 'read',
+ 'contextlevel' => CONTEXT_SYSTEM,
+ 'legacy' => array(
+ 'guest' => CAP_PREVENT,
+ 'student' => CAP_PREVENT,
+ 'teacher' => CAP_ALLOW,
+ 'editingteacher' => CAP_ALLOW,
+ 'coursecreator' => CAP_ALLOW,
+ 'admin' => CAP_ALLOW
+ )
)
);
function page_doc_link($text='', $iconpath='') {
global $ME, $CFG;
- if (empty($CFG->docroot) || !isteacherinanycourse()) {
+ if (empty($CFG->docroot) || !has_capability('moodle/site:doclinks')) {
return '';
}
// vim:autoindent:expandtab:shiftwidth=4:tabstop=4:tw=140:
-?>
\ No newline at end of file
+?>
// This is compared against the values stored in the database to determine
// whether upgrades should be performed (see lib/db/*.php)
- $version = 2006090200; // YYYYMMDD = date
+ $version = 2006090300; // YYYYMMDD = date
// XY = increments within a single day
$release = '1.7 dev'; // Human-friendly version name