mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 08:26:37 +02:00
MDL-23302 Credit to Aparup. New cap moodle/user:manageownfiles to control private user files area
This commit is contained in:
parent
a2580005a5
commit
e4f413b4b3
4 changed files with 19 additions and 4 deletions
|
@ -60,7 +60,9 @@ class block_private_files extends block_base {
|
|||
|
||||
$renderer = $this->page->get_renderer('block_private_files');
|
||||
$this->content->text = $renderer->private_files_tree();
|
||||
$this->content->text .= $OUTPUT->single_button(new moodle_url('/user/filesedit.php'), get_string('myfilesmanage'), 'get');
|
||||
if (has_capability('moodle/user:manageownfiles', $this->context)) {
|
||||
$this->content->text .= $OUTPUT->single_button(new moodle_url('/user/filesedit.php'), get_string('myfilesmanage'), 'get');
|
||||
}
|
||||
$this->content->footer = '';
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue