Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
moodle
moodle
Commits
a3de1eff
Commit
a3de1eff
authored
Mar 22, 2022
by
Sara Arjona
Browse files
Merge branch 'MDL-74160-master' of
https://github.com/ferranrecio/moodle
parents
d5ade9c6
ce7edab8
Changes
3
Hide whitespace changes
Inline
Side-by-side
course/format/classes/output/section_renderer.php
View file @
a3de1eff
...
...
@@ -413,6 +413,34 @@ abstract class section_renderer extends core_course_renderer {
return
$o
;
}
/**
* Generate the starting container html for a list of sections.
*
* @deprecated since 4.0 MDL-72656 - use core_course output components instead.
*
* @return string HTML to output.
*/
protected
function
start_section_list
()
{
debugging
(
'start_section_list() is deprecated. Please use '
.
'core_courseformat\\output\\local\\content\\section to render individual sections or .'
.
'core_courseformat\\output\\local\\content to render the full course'
,
DEBUG_DEVELOPER
);
return
html_writer
::
start_tag
(
'ul'
,
[
'class'
=>
'sections'
]);
}
/**
* Generate the closing container html for a list of sections.
*
* @deprecated since 4.0 MDL-72656 - use core_course output components instead.y
*
* @return string HTML to output.
*/
protected
function
end_section_list
()
{
debugging
(
'end_section_list() is deprecated. Please use '
.
'core_courseformat\\output\\local\\content\\section to render individual sections or .'
.
'core_courseformat\\output\\local\\content to render the full course'
,
DEBUG_DEVELOPER
);
return
html_writer
::
end_tag
(
'ul'
);
}
/**
* Old method to print section edit controls. Do not use it!
*
...
...
course/renderer.php
View file @
a3de1eff
...
...
@@ -823,10 +823,8 @@ class core_course_renderer extends plugin_renderer_base {
$mod
->
get_section_info
(),
$mod
,
);
$renderer
=
$format
->
get_renderer
(
$this
->
page
);
$data
=
$availability
->
export_for_template
(
$renderer
);
return
$data
->
info
??
''
;
return
$renderer
->
render
(
$availability
);
}
/**
...
...
course/upgrade.txt
View file @
a3de1eff
...
...
@@ -56,9 +56,9 @@ renderer and course format renderer:
- course_section_cm_name_title (replaced by core_courseformat\output\local\cm\title)
- course_section_cm_text (integrated in core_courseformat\output\local\content\cm)
- course_section_cm_availability (replaced by core_courseformat\output\local\content\cm\availability))
* The following abstract methods are deleted:
- start_section_list (integrated in core_courseformat\output\local\content)
- end_section_list (integrated in core_courseformat\output\local\content)
* The following abstract methods are deleted:
- page_title (moved to core_courseformat\output\local\content)
* Course formats should have a renderer (until now it was only highly recommended but not mandatory). For backwards
compatibility (to not break third-party plugins without it), legacy_format_renderer has been created and will be used when
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment