MDL-67791 mod_h5pactivity: adding review attempts capability
authorFerran Recio <ferran@moodle.com>
Thu, 23 Apr 2020 16:06:55 +0000 (18:06 +0200)
committerFerran Recio <ferran@moodle.com>
Thu, 14 May 2020 09:54:33 +0000 (11:54 +0200)
mod/h5pactivity/db/access.php
mod/h5pactivity/lang/en/h5pactivity.php

index cef7aba..c0240a1 100644 (file)
@@ -56,4 +56,15 @@ $capabilities = [
             'student' => CAP_ALLOW
         ],
     ],
+
+    'mod/h5pactivity:reviewattempts' => array(
+        'captype' => 'write',
+        'contextlevel' => CONTEXT_MODULE,
+        'archetypes' => array(
+            'teacher' => CAP_ALLOW,
+            'editingteacher' => CAP_ALLOW,
+            'manager' => CAP_ALLOW
+        ),
+        'clonepermissionsfrom' => 'moodle/grade:manage'
+    ),
 ];
index c855830..51d84a1 100644 (file)
@@ -47,6 +47,7 @@ $string['grade_average_attempt'] = 'Average grade';
 $string['grade_last_attempt'] = 'Last attempt';
 $string['grade_first_attempt'] = 'First attempt';
 $string['h5pactivity:addinstance'] = 'Add a new H5P';
+$string['h5pactivity:reviewattempts'] = 'Review H5P attempts';
 $string['h5pactivity:submit'] = 'Submit H5P attempts';
 $string['h5pactivity:view'] = 'View H5P';
 $string['h5pactivityfieldset'] = 'H5P settings';