. /** * Renderer for outputting the weeks course format. * * @package format_weeks * @copyright 2012 Dan Poltawski * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later * @since Moodle 2.3 */ namespace format_weeks\output; use core_courseformat\output\section_renderer; /** * Basic renderer for weeks format. * * @copyright 2012 Dan Poltawski * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later */ class renderer extends section_renderer { /** * Generate the section title, wraps it in a link to the section page if page is to be displayed on a separate page * * @param stdClass $section The course_section entry from DB * @param stdClass $course The course entry from DB * @return string HTML to output. */ public function section_title($section, $course) { return $this->render(course_get_format($course)->inplace_editable_render_section_name($section)); } /** * Generate the section title to be displayed on the section page, without a link * * @param stdClass $section The course_section entry from DB * @param stdClass $course The course entry from DB * @return string HTML to output. */ public function section_title_without_link($section, $course) { return $this->render(course_get_format($course)->inplace_editable_render_section_name($section, false)); } }