mirror of
https://github.com/moodle/moodle.git
synced 2025-08-03 16:13:28 +02:00
MDL-20712 using just $capablities for capability definition array, all other files in db/* do not use component names in definition array; old capability array names are of course supported
This commit is contained in:
parent
e3acc8af7a
commit
0ac940b3bf
64 changed files with 92 additions and 124 deletions
|
@ -23,7 +23,7 @@
|
||||||
// //
|
// //
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
$report_courseoverview_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'report/courseoverview:view' => array(
|
'report/courseoverview:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
// //
|
// //
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
$report_questioninstances_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'report/questioninstances:view' => array(
|
'report/questioninstances:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
// //
|
// //
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
$report_security_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'report/security:view' => array(
|
'report/security:view' => array(
|
||||||
'riskbitmask' => RISK_CONFIG,
|
'riskbitmask' => RISK_CONFIG,
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
// //
|
// //
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
$report_unittest_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'report/unittest:view' => array(
|
'report/unittest:view' => array(
|
||||||
'riskbitmask' => RISK_DATALOSS,
|
'riskbitmask' => RISK_DATALOSS,
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
// //
|
// //
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
$block_online_users_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'block/online_users:viewlist' => array(
|
'block/online_users:viewlist' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$block_rss_client_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'block/rss_client:manageownfeeds' => array(
|
'block/rss_client:manageownfeeds' => array(
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
// //
|
// //
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
$coursereport_log_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'coursereport/log:view' => array(
|
'coursereport/log:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
// //
|
// //
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
$coursereport_outline_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'coursereport/outline:view' => array(
|
'coursereport/outline:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
// //
|
// //
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
$coursereport_participation_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'coursereport/participation:view' => array(
|
'coursereport/participation:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
// //
|
// //
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
$coursereport_progress_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'coursereport/progress:view' => array(
|
'coursereport/progress:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
// //
|
// //
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
$coursereport_stats_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'coursereport/stats:view' => array(
|
'coursereport/stats:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$enrol_authorize_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'enrol/authorize:managepayments' => array(
|
'enrol/authorize:managepayments' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
$gradeexport_ods_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'gradeexport/ods:view' => array(
|
'gradeexport/ods:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
$gradeexport_txt_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'gradeexport/txt:view' => array(
|
'gradeexport/txt:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
$gradeexport_xls_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'gradeexport/xls:view' => array(
|
'gradeexport/xls:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
$gradeexport_xml_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'gradeexport/xml:view' => array(
|
'gradeexport/xml:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
$gradeimport_csv_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'gradeimport/csv:view' => array(
|
'gradeimport/csv:view' => array(
|
||||||
'captype' => 'write',
|
'captype' => 'write',
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
$gradeimport_xml_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'gradeimport/xml:view' => array(
|
'gradeimport/xml:view' => array(
|
||||||
'captype' => 'write',
|
'captype' => 'write',
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
$gradereport_grader_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'gradereport/grader:view' => array(
|
'gradereport/grader:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
$gradereport_outcomes_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'gradereport/outcomes:view' => array(
|
'gradereport/outcomes:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
$gradereport_overview_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'gradereport/overview:view' => array(
|
'gradereport/overview:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
$gradereport_user_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'gradereport/user:view' => array(
|
'gradereport/user:view' => array(
|
||||||
'riskbitmask' => RISK_PERSONAL,
|
'riskbitmask' => RISK_PERSONAL,
|
||||||
|
|
|
@ -3177,7 +3177,11 @@ function load_capability_def($component) {
|
||||||
$capabilities = array();
|
$capabilities = array();
|
||||||
if (file_exists($defpath)) {
|
if (file_exists($defpath)) {
|
||||||
require($defpath);
|
require($defpath);
|
||||||
$capabilities = ${$component.'_capabilities'};
|
if (!empty(${$component.'_capabilities'})) {
|
||||||
|
// legacy capability array name
|
||||||
|
// since 2.0 we prefer $capabilities instead - it is easier to use and matches db/* files
|
||||||
|
$capabilities = ${$component.'_capabilities'};
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return $capabilities;
|
return $capabilities;
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$moodle_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'moodle/site:doanything' => array(
|
'moodle/site:doanything' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$mod_assignment_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/assignment:view' => array(
|
'mod/assignment:view' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$mod_chat_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/chat:chat' => array(
|
'mod/chat:chat' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$mod_choice_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/choice:choose' => array(
|
'mod/choice:choose' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$mod_data_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/data:viewentry' => array(
|
'mod/data:viewentry' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$mod_feedback_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/feedback:view' => array(
|
'mod/feedback:view' => array(
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$mod_folder_capabilities = array(
|
$capabilities = array(
|
||||||
/* TODO: review public portfolio API first!
|
/* TODO: review public portfolio API first!
|
||||||
'mod/folder:portfolioexport' => array(
|
'mod/folder:portfolioexport' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$mod_forum_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/forum:viewdiscussion' => array(
|
'mod/forum:viewdiscussion' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$mod_glossary_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/glossary:write' => array(
|
'mod/glossary:write' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$mod_hotpot_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/hotpot:attempt' => array(
|
'mod/hotpot:attempt' => array(
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$mod_imscp_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
/* TODO: review public portfolio API first!
|
/* TODO: review public portfolio API first!
|
||||||
'mod/imscp:portfolioexport' => array(
|
'mod/imscp:portfolioexport' => array(
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* For naming conventions, see lib/db/access.php.
|
* For naming conventions, see lib/db/access.php.
|
||||||
*/
|
*/
|
||||||
$mod_lesson_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/lesson:edit' => array(
|
'mod/lesson:edit' => array(
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$mod_page_capabilities = array(
|
$capabilities = array(
|
||||||
/* TODO: review public portfolio API first!
|
/* TODO: review public portfolio API first!
|
||||||
'mod/page:portfolioexport' => array(
|
'mod/page:portfolioexport' => array(
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* For naming conventions, see lib/db/access.php.
|
* For naming conventions, see lib/db/access.php.
|
||||||
*/
|
*/
|
||||||
$mod_quiz_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
// Ability to see that the quiz exists, and the basic information
|
// Ability to see that the quiz exists, and the basic information
|
||||||
// about it, for example the start date and time limit.
|
// about it, for example the start date and time limit.
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* For naming conventions, see lib/db/access.php.
|
* For naming conventions, see lib/db/access.php.
|
||||||
*/
|
*/
|
||||||
$quiz_statistics_capabilities = array(
|
$capabilities = array(
|
||||||
'quizreport/statistics:view' => array(
|
'quizreport/statistics:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
'contextlevel' => CONTEXT_MODULE,
|
'contextlevel' => CONTEXT_MODULE,
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$mod_resource_capabilities = array(
|
$capabilities = array(
|
||||||
/* TODO: review public portfolio API first!
|
/* TODO: review public portfolio API first!
|
||||||
'mod/resource:portfolioexport' => array(
|
'mod/resource:portfolioexport' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$mod_scorm_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/scorm:viewreport' => array(
|
'mod/scorm:viewreport' => array(
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
//
|
//
|
||||||
// It is important that capability names are unique. The naming convention
|
// It is important that capability names are unique. The naming convention
|
||||||
// for capabilities that are specific to modules and blocks is as follows:
|
// for capabilities that are specific to modules and blocks is as follows:
|
||||||
// [mod/block]/<component_name>:<capabilityname>
|
// [mod/block]/<plugin_name>:<capabilityname>
|
||||||
//
|
//
|
||||||
// component_name should be the same as the directory name of the mod or block.
|
// component_name should be the same as the directory name of the mod or block.
|
||||||
//
|
//
|
||||||
|
@ -25,13 +25,10 @@
|
||||||
// block/recent_activity:view
|
// block/recent_activity:view
|
||||||
// moodle/site:deleteuser
|
// moodle/site:deleteuser
|
||||||
//
|
//
|
||||||
// The variable name for the capability definitions array follows the format
|
// The variable name for the capability definitions array is $capabilities
|
||||||
// $<componenttype>_<component_name>_capabilities
|
|
||||||
//
|
|
||||||
// For the core capabilities, the variable is $moodle_capabilities.
|
|
||||||
|
|
||||||
|
|
||||||
$mod_survey_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/survey:participate' => array(
|
'mod/survey:participate' => array(
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$mod_url_capabilities = array(
|
$capabilities = array(
|
||||||
/* TODO: review public portfolio API first!
|
/* TODO: review public portfolio API first!
|
||||||
'mod/url:portfolioexport' => array(
|
'mod/url:portfolioexport' => array(
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* For naming conventions, see lib/db/access.php.
|
* For naming conventions, see lib/db/access.php.
|
||||||
*/
|
*/
|
||||||
$mod_wiki_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'mod/wiki:participate' => array(
|
'mod/wiki:participate' => array(
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_alfresco_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/alfresco:view' => array(
|
'repository/alfresco:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_boxnet_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/boxnet:view' => array(
|
'repository/boxnet:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_draft_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/draft:view' => array(
|
'repository/draft:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_filesystem_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/filesystem:view' => array(
|
'repository/filesystem:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_flickr_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/flickr:view' => array(
|
'repository/flickr:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_flickr_public_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/flickr_public:view' => array(
|
'repository/flickr_public:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_googledocs_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/googledocs:view' => array(
|
'repository/googledocs:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_local_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/local:view' => array(
|
'repository/local:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_mahara_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/mahara:view' => array(
|
'repository/mahara:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_picasa_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/picasa:view' => array(
|
'repository/picasa:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_remotemoodle_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/remotemoodle:view' => array(
|
'repository/remotemoodle:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_s3_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/s3:view' => array(
|
'repository/s3:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_upload_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/upload:view' => array(
|
'repository/upload:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_url_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/url:view' => array(
|
'repository/url:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_webdav_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/webdav:view' => array(
|
'repository/webdav:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_wikimedia_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/wikimedia:view' => array(
|
'repository/wikimedia:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$repository_youtube_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'repository/youtube:view' => array(
|
'repository/youtube:view' => array(
|
||||||
'captype' => 'read',
|
'captype' => 'read',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$webservice_amf_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'webservice/amf:use' => array(
|
'webservice/amf:use' => array(
|
||||||
'captype' => 'read', // in fact this may be considered read and write at the same time
|
'captype' => 'read', // in fact this may be considered read and write at the same time
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$webservice_rest_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'webservice/rest:use' => array(
|
'webservice/rest:use' => array(
|
||||||
'captype' => 'read', // in fact this may be considered read and write at the same time
|
'captype' => 'read', // in fact this may be considered read and write at the same time
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$webservice_soap_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'webservice/soap:use' => array(
|
'webservice/soap:use' => array(
|
||||||
'captype' => 'read', // in fact this may be considered read and write at the same time
|
'captype' => 'read', // in fact this may be considered read and write at the same time
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$webservice_xmlrpc_capabilities = array(
|
$capabilities = array(
|
||||||
|
|
||||||
'webservice/xmlrpc:use' => array(
|
'webservice/xmlrpc:use' => array(
|
||||||
'captype' => 'read', // in fact this may be considered read and write at the same time
|
'captype' => 'read', // in fact this may be considered read and write at the same time
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue