MDL-82260 core_courseformat: sync subsections access restrictions
This commit is contained in:
@@ -22,6 +22,7 @@ use section_info;
|
||||
use core_courseformat\stateupdates;
|
||||
use core_courseformat\output\local\content\section\controlmenu;
|
||||
use core_courseformat\base as course_format;
|
||||
use stdClass;
|
||||
|
||||
/**
|
||||
* Section delegate base class.
|
||||
@@ -133,4 +134,18 @@ abstract class sectiondelegate {
|
||||
public function get_parent_section(): ?section_info {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Handler executed when a section has been updated.
|
||||
*
|
||||
* This method uses a record instead of a section_info object because
|
||||
* section updates can be done in batch and the course_info may not be yet updated.
|
||||
*
|
||||
* This method does not need to recalculate the section_info object.
|
||||
*
|
||||
* @param stdClass $sectionrecord the new section data
|
||||
*/
|
||||
public function section_updated(stdClass $sectionrecord): void {
|
||||
// By default, do nothing.
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user