MDL-14627 new mod/folder:view capability
[moodle.git] / mod / folder / db / access.php
CommitLineData
0e16b939 1<?php
2
3// This file is part of Moodle - http://moodle.org/
4//
5// Moodle is free software: you can redistribute it and/or modify
6// it under the terms of the GNU General Public License as published by
7// the Free Software Foundation, either version 3 of the License, or
8// (at your option) any later version.
9//
10// Moodle is distributed in the hope that it will be useful,
11// but WITHOUT ANY WARRANTY; without even the implied warranty of
12// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13// GNU General Public License for more details.
14//
15// You should have received a copy of the GNU General Public License
16// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
17
18/**
19 * Capability definitions for the folder module.
20 *
9fe1fbcc
PS
21 * @package mod
22 * @subpackage folder
23 * @copyright 2009 Petr Skoda {@link http://skodak.org}
24 * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
0e16b939 25 */
26
9fe1fbcc
PS
27defined('MOODLE_INTERNAL') || die();
28
0ac940b3 29$capabilities = array(
9093de63
PS
30 'mod/folder:view' => array(
31 'captype' => 'read',
32 'contextlevel' => CONTEXT_MODULE,
33 'archetypes' => array(
34 'guest' => CAP_ALLOW,
35 'user' => CAP_ALLOW,
36 )
37 ),
38
0e16b939 39/* TODO: review public portfolio API first!
40 'mod/folder:portfolioexport' => array(
41
42 'captype' => 'read',
43 'contextlevel' => CONTEXT_MODULE,
31c93303 44 'archetypes' => array(
0e16b939 45 'teacher' => CAP_ALLOW,
46 'editingteacher' => CAP_ALLOW,
47 )
48 ),*/
49
a2580005
MD
50 // can manage files in the folder
51 'mod/folder:managefiles' => array(
8664a86f 52 'riskbitmask' => RISK_SPAM,
a2580005
MD
53 'captype' => 'write',
54 'contextlevel' => CONTEXT_MODULE,
55 'archetypes' => array(
56 'editingteacher' => CAP_ALLOW
57 )
58 )
0e16b939 59);
60