[ Index ]

PHP Cross Reference of moodle-2.8

title

Body

[close]

/mod/feedback/db/ -> access.php (source)

   1  <?php
   2  // This file is part of Moodle - http://moodle.org/
   3  //
   4  // Moodle is free software: you can redistribute it and/or modify
   5  // it under the terms of the GNU General Public License as published by
   6  // the Free Software Foundation, either version 3 of the License, or
   7  // (at your option) any later version.
   8  //
   9  // Moodle is distributed in the hope that it will be useful,
  10  // but WITHOUT ANY WARRANTY; without even the implied warranty of
  11  // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  12  // GNU General Public License for more details.
  13  //
  14  // You should have received a copy of the GNU General Public License
  15  // along with Moodle.  If not, see <http://www.gnu.org/licenses/>.
  16  
  17  /**
  18   * Plugin capabilities
  19   *
  20   * @package    mod_feedback
  21   * @copyright  Andreas Grabs
  22   * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
  23   */
  24  
  25  defined('MOODLE_INTERNAL') || die();
  26  
  27  $capabilities = array(
  28  
  29      'mod/feedback:addinstance' => array(
  30          'riskbitmask' => RISK_XSS,
  31  
  32          'captype' => 'write',
  33          'contextlevel' => CONTEXT_COURSE,
  34          'archetypes' => array(
  35              'editingteacher' => CAP_ALLOW,
  36              'manager' => CAP_ALLOW
  37          ),
  38          'clonepermissionsfrom' => 'moodle/course:manageactivities'
  39      ),
  40  
  41      'mod/feedback:view' => array(
  42  
  43          'captype' => 'read',
  44          'contextlevel' => CONTEXT_MODULE,
  45          'archetypes' => array(
  46              'guest' => CAP_ALLOW,
  47              'student' => CAP_ALLOW,
  48              'teacher' => CAP_ALLOW,
  49              'editingteacher' => CAP_ALLOW,
  50              'manager' => CAP_ALLOW
  51          )
  52      ),
  53  
  54      'mod/feedback:complete' => array(
  55  
  56          'riskbitmask' => RISK_SPAM,
  57  
  58          'captype' => 'write',
  59          'contextlevel' => CONTEXT_MODULE,
  60          'archetypes' => array(
  61              'student' => CAP_ALLOW
  62          )
  63      ),
  64  
  65      'mod/feedback:viewanalysepage' => array(
  66  
  67          'riskbitmask' => RISK_PERSONAL,
  68  
  69          'captype' => 'read',
  70          'contextlevel' => CONTEXT_MODULE,
  71          'archetypes' => array(
  72              'student' => CAP_ALLOW,
  73              'editingteacher' => CAP_ALLOW,
  74              'manager' => CAP_ALLOW
  75          )
  76      ),
  77  
  78      'mod/feedback:deletesubmissions' => array(
  79  
  80          'captype' => 'write',
  81          'contextlevel' => CONTEXT_MODULE,
  82          'archetypes' => array(
  83              'editingteacher' => CAP_ALLOW,
  84              'manager' => CAP_ALLOW
  85          )
  86      ),
  87  
  88      'mod/feedback:mapcourse' => array(
  89  
  90          'captype' => 'write',
  91          'contextlevel' => CONTEXT_MODULE,
  92          'archetypes' => array(
  93              'manager' => CAP_ALLOW
  94          )
  95      ),
  96  
  97      'mod/feedback:edititems' => array(
  98  
  99          'riskbitmask' => RISK_SPAM | RISK_XSS,
 100  
 101          'captype' => 'write',
 102          'contextlevel' => CONTEXT_MODULE,
 103          'archetypes' => array(
 104              'editingteacher' => CAP_ALLOW,
 105              'manager' => CAP_ALLOW
 106          )
 107      ),
 108  
 109      'mod/feedback:createprivatetemplate' => array(
 110  
 111          'riskbitmask' => RISK_SPAM,
 112  
 113          'captype' => 'write',
 114          'contextlevel' => CONTEXT_MODULE,
 115          'archetypes' => array(
 116              'editingteacher' => CAP_ALLOW,
 117              'manager' => CAP_ALLOW
 118          )
 119      ),
 120  
 121      'mod/feedback:createpublictemplate' => array(
 122  
 123          'riskbitmask' => RISK_SPAM,
 124  
 125          'captype' => 'write',
 126          'contextlevel' => CONTEXT_MODULE,
 127          'archetypes' => array(
 128              'editingteacher' => CAP_ALLOW,
 129              'manager' => CAP_ALLOW
 130          )
 131      ),
 132  
 133      'mod/feedback:deletetemplate' => array(
 134  
 135          'captype' => 'write',
 136          'contextlevel' => CONTEXT_MODULE,
 137          'archetypes' => array(
 138              'editingteacher' => CAP_ALLOW,
 139              'manager' => CAP_ALLOW
 140          )
 141      ),
 142  
 143      'mod/feedback:viewreports' => array(
 144  
 145          'riskbitmask' => RISK_PERSONAL,
 146  
 147          'captype' => 'read',
 148          'contextlevel' => CONTEXT_MODULE,
 149          'archetypes' => array(
 150              'teacher' => CAP_ALLOW,
 151              'editingteacher' => CAP_ALLOW,
 152              'manager' => CAP_ALLOW
 153          )
 154      ),
 155  
 156      'mod/feedback:receivemail' => array(
 157  
 158          'riskbitmask' => RISK_PERSONAL,
 159  
 160          'captype' => 'read',
 161          'contextlevel' => CONTEXT_MODULE,
 162          'archetypes' => array(
 163              'teacher' => CAP_ALLOW,
 164              'editingteacher' => CAP_ALLOW
 165          )
 166      ),
 167  
 168  );
 169  
 170  


Generated: Fri Nov 28 20:29:05 2014 Cross-referenced by PHPXref 0.7.1