Merge branch 'MDL-79664' of https://github.com/paulholden/moodle
[moodle.git] / mod / lesson / upgrade.txt
blob0ce6fa5997cb51b9d59f3c130315fdbf3d1c4d87
1 This files describes API changes in the lesson code.
3 === 4.4 ===
5 * The deprecated `lesson_add_header_buttons` method has been removed
7 === 4.0 ===
8 * Deprecated the function lesson_add_header_buttons in favour of tertiary navigation.
10 === 3.6.1 ===
12 * A new function update_form_data() has been added to lesson_page class. This can be overridden by the individual page types
13   to alter the form data before being sent to the mform.
15 === 3.4 ===
17 * External function mod_lesson_external::get_user_attempt() now returns the full page object inside each answerpages.
19 === 3.3.2 ===
21 * lesson_refresh_events() Now takes two additional parameters to refine the update to a specific instance. This function
22   now optionally takes the module instance object or ID, and the course module object or ID. Please try to send the full
23   objects instead of the ids to save DB calls.
25 === 3.3 ===
27 * lesson::callback_on_view() has an additional optional parameter $redirect default to true.
28   It can be set to false to avoid redirection and return the page to redirect.
29 === 3.1 ===
30 * Removed the unused file reformat.php
31 * removedoublecr() and importmodifiedaikenstyle() have now been removed.
33 === 3.0 ===
34 * Removed broken high score code.  Use the activity results block instead.
36 === 2.9 ===
37 * The  grade_item_delete function in mod/lesson/lib.php was removed because it was not doing anything and was never called.
38 * A third optional boolean parameter $endreached was added to lesson::update_timer to indicate that end of lesson was reached. This is used by 'completionendreached' custom completion rule.
39 * lesson_page_type_endofbranch::update in mod/lesson/pagetypes/endofbranch.php
40   and lesson_page_type_endofcluster::update in mod/lesson/pagetypes/endofcluster.php
41   have been removed, this is now handled by the base class: lesson_page::update in
42   locallib.php and the exact same code is executed (it is also executed by the
43   lesson_page_type_cluster class that previously had no update function).
44 * A fourth parameter (format) has been added to the add_answer() function
45   located as part of the lesson_add_page_form_base class. If specified with a value of 'LESSON_ANSWER_HTML'
46   then a rich html editor is generated. Otherwise an editor is created with Moodle Auto Format
47 * removedoublecr() and importmodifiedaikenstyle() are now deprecated.
48 * Added support for groups and groupings. If enabled, this allows the Report and
49   Grade Essay view to be filtered by a group
51 === Earlier changes ===
53 * Were not documented in this way. Sorry.