From 7727745bf79a78403c69207f800b6d47d4e169d3 Mon Sep 17 00:00:00 2001 From: Huong Nguyen Date: Wed, 8 Mar 2023 21:35:54 +0700 Subject: [PATCH] MDL-75316 core_moodlenet: Create MoodleNet capability Originally implemented as MDL-75319 --- lang/en/role.php | 1 + lib/db/access.php | 10 ++++++++++ version.php | 2 +- 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/lang/en/role.php b/lang/en/role.php index 0febe58a301df..5f9b0ff7f0021 100644 --- a/lang/en/role.php +++ b/lang/en/role.php @@ -309,6 +309,7 @@ $string['managerdescription'] = 'Managers can access courses and modify them, but usually do not participate in them.'; $string['manageroles'] = 'Manage roles'; $string['maybeassignedin'] = 'Context types where this role may be assigned'; +$string['moodlenet:shareactivity'] = 'Share activities to MoodleNet'; $string['morethan'] = 'More than {$a}'; $string['multipleroles'] = 'Multiple roles'; $string['my:manageblocks'] = 'Manage Dashboard page blocks'; diff --git a/lib/db/access.php b/lib/db/access.php index 6cccb63042ac0..37bd3aa509baa 100644 --- a/lib/db/access.php +++ b/lib/db/access.php @@ -2681,4 +2681,14 @@ 'contextlevel' => CONTEXT_SYSTEM, 'archetypes' => [], ], + + // Allow users to share activities to MoodleNet. + 'moodle/moodlenet:shareactivity' => [ + 'captype' => 'read', + 'contextlevel' => CONTEXT_COURSE, + 'archetypes' => [ + 'editingteacher' => CAP_ALLOW, + 'manager' => CAP_ALLOW, + ] + ], ); diff --git a/version.php b/version.php index 0cee84b39c7a0..7bcc48cbbcc98 100644 --- a/version.php +++ b/version.php @@ -29,7 +29,7 @@ defined('MOODLE_INTERNAL') || die(); -$version = 2023041400.00; // YYYYMMDD = weekly release date of this DEV branch. +$version = 2023041400.01; // YYYYMMDD = weekly release date of this DEV branch. // RR = release increments - 00 in DEV branches. // .XX = incremental changes. $release = '4.2beta (Build: 20230414)'; // Human-friendly version name