Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 3.11.x will end 14 Nov 2022 (12 months plus 6 months extension).
  • Bug fixes for security issues in 3.11.x will end 13 Nov 2023 (18 months plus 12 months extension).
  • PHP version: minimum PHP 7.3.0 Note: minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is supported too.

Differences Between: [Versions 311 and 400] [Versions 311 and 401] [Versions 311 and 402] [Versions 311 and 403]

Data registry renderable.

Copyright: 2018 David Monllao
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 476 lines (16 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class


Class: data_registry_page  - X-Ref

Class containing the data registry renderable

__construct($defaultcontextlevel = false, $defaultcontextid = false)   X-Ref
Constructor.

param: int $defaultcontextlevel
param: int $defaultcontextid
return: null

export_for_template(renderer_base $output)   X-Ref
Export this data so it can be used as the context for a mustache template.

param: renderer_base $output
return: stdClass

get_default_tree_structure()   X-Ref
Returns the tree default structure.

return: array

get_all_category_branches()   X-Ref
Returns the hierarchy of system course categories.

return: array

get_courses_branch(\context $catcontext)   X-Ref
Gets the courses branch for the provided category.

param: \context $catcontext
return: array

get_modules_branch(\context $coursecontext)   X-Ref
Gets the modules branch for the provided course.

param: \context $coursecontext
return: array

get_blocks_branch(\context $coursecontext)   X-Ref
Gets the blocks branch for the provided course.

param: \context $coursecontext
return: null

add_to_parent_category_branch($category, $newnode, &$categoriesbranch)   X-Ref
Adds the provided category to the categories branch.

param: stdClass $category
param: array $newnode
param: array $categoriesbranch
return: bool

complete($node, $currentcontextlevel = false, $currentcontextid = false)   X-Ref
Completes tree nodes with default values.

param: array $node
param: int|false $currentcontextlevel
param: int|false $currentcontextid
return: array

purpose_options($purposes, $includenotset = true, $includeinherit = true)   X-Ref
From a list of purpose persistents to a list of id => name purposes.

param: \tool_dataprivacy\purpose[] $purposes
param: bool $includenotset
param: bool $includeinherit
return: string[]

category_options($categories, $includenotset = true, $includeinherit = true)   X-Ref
From a list of category persistents to a list of id => name categories.

param: \tool_dataprivacy\category[] $categories
param: bool $includenotset
param: bool $includeinherit
return: string[]

base_options($includenotset = true, $includeinherit = true)   X-Ref
Base not set and inherit options.

param: bool $includenotset
param: bool $includeinherit
return: array