Merge branch 'MDL-69270-master' of git://github.com/ferranrecio/moodle
[moodle.git] / contentbank / view.php
index 64ecf74..4c84b1b 100644 (file)
@@ -93,6 +93,15 @@ if ($contenttype->can_manage($content)) {
         ));
     }
 }
+if ($contenttype->can_download($content)) {
+    // Add the download content item to the menu.
+    $actionmenu->add_secondary_action(new action_menu_link(
+        new moodle_url($contenttype->get_download_url($content)),
+        new pix_icon('t/download', get_string('download')),
+        get_string('download'),
+        false
+    ));
+}
 if ($contenttype->can_delete($content)) {
     // Add the delete content item to the menu.
     $attributes = [