mirror of
https://github.com/moodle/moodle.git
synced 2025-03-31 22:12:56 +02:00
The method can_edit_content() now supports more scenarios where the H5P content can be edited: - Instead of supporting only mod_h5pactivity, now it supports any mod or block when the user has the addinstance capability. - If the component implements the can_edit_content method in the h5p\canedit class and it returns true. For instance, the mod_forum implements it and return true when filearea is post, if the user can edit the post where the H5P is.
34 lines
1.8 KiB
Plaintext
34 lines
1.8 KiB
Plaintext
This files describes API changes in core libraries and APIs,
|
|
information provided here is intended especially for developers.
|
|
|
|
=== 4.0 ===
|
|
* Added new methods to api: get_original_content_from_pluginfile_url and can_edit_content.
|
|
* Added edit.php and editcontent_form class, for modifying H5P content given an H5P identifier (from the h5p table).
|
|
* Added a new parameter to the player::display method, to define whether the edit button should be displayed below the
|
|
H5P content or not. Default value for this parameter is false.
|
|
* H5P subsystem is allowed to act as an API (level 2) too.
|
|
* Plugins can now implement h5p\canedit::can_edit_content method to define, if required, any custom behaviour for deciding
|
|
whether an H5P content can be edited or not. The specific plugin check will completely override the generic check.
|
|
|
|
=== 3.11 ===
|
|
* Added $skipcapcheck parameter to H5P constructor, api::create_content_from_pluginfile_url() and
|
|
api::get_content_from_pluginfile_url() to let skip capabilities check to get the pluginfile URL.
|
|
* Added new field "enabled" to h5p_libraries to let define if a content type is enabled (1) or not (0).
|
|
For now, only runnable content-types can be disabled/enabled. When a content-type is disabled, their
|
|
contents are not displayed and no new contents using it can be created/uploaded.
|
|
Some extra methods have been added to the api too in order to support this field:
|
|
- set_library_enabled
|
|
- is_library_enabled
|
|
- is_valid_package
|
|
* The third-party library h5p/h5plib/v124/core has been updated to version 1.24.2.
|
|
|
|
=== 3.10 ===
|
|
* Added a new cache for h5p_library_files (MDL-69207)
|
|
|
|
=== 3.9 ===
|
|
* A new plugintype has been created, h5plib, for having installed more
|
|
than one H5P library version.
|
|
* H5P third-party libraries have been moved from /lib/h5p to h5p/h5plib/v124,
|
|
as an h5plib plugintype.
|
|
* H5P Editor PHP library added to h5plib v124 plugin.
|