1441 |
ariadna |
1 |
# core_course (subsystem) Upgrade notes
|
|
|
2 |
|
|
|
3 |
## 5.0
|
|
|
4 |
|
|
|
5 |
### Added
|
|
|
6 |
|
|
|
7 |
- Now the core_courseformat\local\content\cm\completion output is more reusable. All the HTML has been moved to its own mustache file, and the output class has a new set_smallbutton method to decide wether to rendered it as a small button (like in the course page) or as a normal one (for other types of pages).
|
|
|
8 |
|
|
|
9 |
For more information see [MDL-83872](https://tracker.moodle.org/browse/MDL-83872)
|
|
|
10 |
- New core_course\output\activity_icon class to render activity icons with or without purpose color. This output will centralize the way Moodle renders activity icons
|
|
|
11 |
|
|
|
12 |
For more information see [MDL-84555](https://tracker.moodle.org/browse/MDL-84555)
|
|
|
13 |
|
|
|
14 |
### Deprecated
|
|
|
15 |
|
|
|
16 |
- The core_course_edit_module and core_course_edit_section external functions are now deprecated. Use core_courseformat_update_course instead
|
|
|
17 |
|
|
|
18 |
For more information see [MDL-82342](https://tracker.moodle.org/browse/MDL-82342)
|
|
|
19 |
- The core_course_get_module external function is now deprecated. Use fragment API using component core_courseformat and fragment cmitem instead
|
|
|
20 |
|
|
|
21 |
For more information see [MDL-82342](https://tracker.moodle.org/browse/MDL-82342)
|
|
|
22 |
- The course_format_ajax_support function is now deprecated. Use course_get_format($course)->supports_ajax() instead.
|
|
|
23 |
|
|
|
24 |
For more information see [MDL-82351](https://tracker.moodle.org/browse/MDL-82351)
|
|
|
25 |
- course_get_cm_edit_actions is now deprecated. Formats should extend core_courseformat\output\local\content\cm\controlmenu instead.
|
|
|
26 |
|
|
|
27 |
For more information see [MDL-83527](https://tracker.moodle.org/browse/MDL-83527)
|
|
|
28 |
|
|
|
29 |
### Removed
|
|
|
30 |
|
|
|
31 |
- Final deprecation of edit_default_completion()
|
|
|
32 |
|
|
|
33 |
For more information see [MDL-78711](https://tracker.moodle.org/browse/MDL-78711)
|
|
|
34 |
- Final removal of core_course\output\activity_information
|
|
|
35 |
|
|
|
36 |
For more information see [MDL-78926](https://tracker.moodle.org/browse/MDL-78926)
|
|
|
37 |
- Final deprecation of core_course_renderer\render_activity_information()
|
|
|
38 |
|
|
|
39 |
For more information see [MDL-78926](https://tracker.moodle.org/browse/MDL-78926)
|
|
|
40 |
|
|
|
41 |
## 4.5
|
|
|
42 |
|
|
|
43 |
### Added
|
|
|
44 |
|
|
|
45 |
- - New optional `sectionNum` parameter has been added to `activitychooser` AMD module initializer.
|
|
|
46 |
- New option `sectionnum` parameter has been added to `get_course_content_items()` external function.
|
|
|
47 |
- New optional `sectionnum` parameter has been added to `get_content_items_for_user_in_course()` function.
|
|
|
48 |
|
|
|
49 |
For more information see [MDL-81675](https://tracker.moodle.org/browse/MDL-81675)
|
|
|
50 |
- The `core_course_get_courses_by_field` web service now accepts a new parameter `sectionid` to be able to retrieve the course that has the indicated section.
|
|
|
51 |
|
|
|
52 |
For more information see [MDL-81699](https://tracker.moodle.org/browse/MDL-81699)
|
|
|
53 |
- Added new `activitychooserbutton` output class to display the activitychooser button. New `action_links` can be added to the button via hooks converting it into a dropdown.
|
|
|
54 |
|
|
|
55 |
For more information see [MDL-81767](https://tracker.moodle.org/browse/MDL-81767)
|
|
|
56 |
- New `\core_course\hook\before_activitychooserbutton_exported` hook added to allow third-party plugins to extend activity chooser button options.
|
|
|
57 |
|
|
|
58 |
For more information see [MDL-81767](https://tracker.moodle.org/browse/MDL-81767)
|
|
|
59 |
- The following methods have been updated to accept a section name in addition to the section number:
|
|
|
60 |
- `\behat_course::i_open_section_edit_menu()`
|
|
|
61 |
- `\behat_course::i_show_section()`
|
|
|
62 |
- `\behat_course::i_hide_section(),`
|
|
|
63 |
- `\behat_course::i_wait_until_section_is_available()`
|
|
|
64 |
- `\behat_course::show_section_link_exists()`
|
|
|
65 |
- `\behat_course::hide_section_link_exists()`
|
|
|
66 |
- `\behat_course::section_exists()`
|
|
|
67 |
|
|
|
68 |
For more information see [MDL-82259](https://tracker.moodle.org/browse/MDL-82259)
|
|
|
69 |
|
|
|
70 |
### Changed
|
|
|
71 |
|
|
|
72 |
- The reset course page has been improved. The words "Delete" and "Remove" have been removed from all the options to make it easier to focus on the data to be removed and avoid inconsistencies and duplicated information. Third party plugins implementing reset methods might need to:
|
|
|
73 |
- Add static element in the _reset_course_form_definition method before all the options with the Delete string:
|
|
|
74 |
`$mform->addElement('static', 'assigndelete', get_string('delete'));`
|
|
|
75 |
- Review all the strings used in the reset page to remove the "Delete" or "Remove" words from them.
|
|
|
76 |
|
|
|
77 |
For more information see [MDL-81872](https://tracker.moodle.org/browse/MDL-81872)
|
|
|
78 |
- The external function `core_course_get_contents` now returns the `component` and `itemid` of sections.
|
|
|
79 |
|
|
|
80 |
For more information see [MDL-82385](https://tracker.moodle.org/browse/MDL-82385)
|
|
|
81 |
|
|
|
82 |
### Deprecated
|
|
|
83 |
|
|
|
84 |
- The `data-sectionid` attribute in the activity chooser has been deprecated. Please update your code to use `data-sectionnum` instead.
|
|
|
85 |
|
|
|
86 |
For more information see [MDL-81676](https://tracker.moodle.org/browse/MDL-81676)
|
|
|
87 |
- The `$course` parameter in the constructor of the `\core_course\output\actionbar\group_selector` class has been deprecated and is no longer used.
|
|
|
88 |
|
|
|
89 |
For more information see [MDL-82393](https://tracker.moodle.org/browse/MDL-82393)
|
|
|
90 |
|
|
|
91 |
### Removed
|
|
|
92 |
|
|
|
93 |
- The previously deprecated `\print_course_request_buttons()` method has been removed and can no longer be used.
|
|
|
94 |
|
|
|
95 |
For more information see [MDL-73976](https://tracker.moodle.org/browse/MDL-73976)
|
|
|
96 |
- The `$course` class property in the `\core_course\output\actionbar\group_selector` class has been removed.
|
|
|
97 |
|
|
|
98 |
For more information see [MDL-82393](https://tracker.moodle.org/browse/MDL-82393)
|