Moodle PHP Documentation 5.0
Moodle 5.0.1+ (Build: 20250711) (61af040cd5f)
tool_dataprivacy\output\data_requests_table Class Reference

The class for displaying the data requests table. More...

Inheritance diagram for tool_dataprivacy\output\data_requests_table:

Public Member Functions

 __construct ($userid=0, $statuses=[], $types=[], $creationmethods=[], $manage=false)
 data_requests_table constructor.
 
 col_actions ($data)
 The actions column.
 
 col_comments ($data)
 The comments column.
 
 col_requestedby ($data)
 The requesting user's column.
 
 col_select ($data)
 The select column.
 
 col_status ($data)
 The status column.
 
 col_timecreated ($data)
 The context information column.
 
 col_type ($data)
 The type column.
 
 col_userid ($data)
 The user column.
 
 get_requests_per_page ()
 Get the number of data request records to be displayed per page.
 
 get_requests_per_page_options ()
 Get the available options for the number of data request to be displayed per page.
 
 print_nothing_to_display ()
 Override default implementation to display a more meaningful information to the user.
 
 query_db ($pagesize, $useinitialsbar=true)
 Query the database for results to display in the table.
 
 set_requests_per_page (int $perpage)
 Set the number of data request records to be displayed per page.
 
 set_requests_per_page_options (array $perpageoptions)
 Set the available options for the number of data request to be displayed per page.
 
 wrap_html_finish ()
 Override the table's wrap_html_finish method in order to render the bulk actions and records per page options.
 

Protected Member Functions

 show_hide_link ($column, $index)
 Override the table's show_hide_link method to prevent the show/hide links from rendering.
 

Protected Attributes

int[] array $creationmethods = []
 The request creation method filters.
 
tool_dataprivacy data_request[] $datarequests = []
 Array of data request persistents.
 
bool $manage = false
 Whether this table is being rendered for managing data requests.
 
stdClass[] $ongoingrequests = []
 List of userids and whether they have any ongoing active requests.
 
int $perpage
 The number of data request to be displayed per page.
 
int[] $perpageoptions = [25, 50, 100, 250]
 The available options for the number of data request to be displayed per page.
 
int[] $statuses = []
 The status filters.
 
int[] $types = []
 The request type filters.
 
int $userid = 0
 The user ID.
 

Detailed Description

The class for displaying the data requests table.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Constructor & Destructor Documentation

◆ __construct()

tool_dataprivacy\output\data_requests_table::__construct ( $userid = 0,
$statuses = [],
$types = [],
$creationmethods = [],
$manage = false )

data_requests_table constructor.

Parameters
int$useridThe user ID
int[]$statuses
int[]$types
int[]$creationmethods
bool$manage
Exceptions
coding_exception

Member Function Documentation

◆ col_actions()

tool_dataprivacy\output\data_requests_table::col_actions ( $data)

The actions column.

Parameters
stdClass$dataThe row data.
Return values
string

◆ col_comments()

tool_dataprivacy\output\data_requests_table::col_comments ( $data)

The comments column.

Parameters
stdClass$dataThe row data.
Return values
string

◆ col_requestedby()

tool_dataprivacy\output\data_requests_table::col_requestedby ( $data)

The requesting user's column.

Parameters
stdClass$dataThe row data.
Return values
mixed

◆ col_select()

tool_dataprivacy\output\data_requests_table::col_select ( $data)

The select column.

Parameters
stdClass$dataThe row data.
Return values
string
Exceptions
moodle_exception
coding_exception

◆ col_status()

tool_dataprivacy\output\data_requests_table::col_status ( $data)

The status column.

Parameters
stdClass$dataThe row data.
Return values
mixed

◆ col_timecreated()

tool_dataprivacy\output\data_requests_table::col_timecreated ( $data)

The context information column.

Parameters
stdClass$dataThe row data.
Return values
string

◆ col_type()

tool_dataprivacy\output\data_requests_table::col_type ( $data)

The type column.

Parameters
stdClass$dataThe row data.
Return values
string

◆ col_userid()

tool_dataprivacy\output\data_requests_table::col_userid ( $data)

The user column.

Parameters
stdClass$dataThe row data.
Return values
mixed

◆ get_requests_per_page()

tool_dataprivacy\output\data_requests_table::get_requests_per_page ( )

Get the number of data request records to be displayed per page.

Return values
intThe number of data request records.

◆ get_requests_per_page_options()

tool_dataprivacy\output\data_requests_table::get_requests_per_page_options ( )

Get the available options for the number of data request to be displayed per page.

Return values
arrayThe available options for the number of data request to be displayed per page.

◆ query_db()

tool_dataprivacy\output\data_requests_table::query_db ( $pagesize,
$useinitialsbar = true )

Query the database for results to display in the table.

Parameters
int$pagesizesize of page for paginated displayed table.
bool$useinitialsbardo you want to use the initials bar.
Exceptions
dml_exception
coding_exception

◆ set_requests_per_page()

tool_dataprivacy\output\data_requests_table::set_requests_per_page ( int $perpage)

Set the number of data request records to be displayed per page.

Parameters
int$perpageThe number of data request records.

◆ set_requests_per_page_options()

tool_dataprivacy\output\data_requests_table::set_requests_per_page_options ( array $perpageoptions)

Set the available options for the number of data request to be displayed per page.

Parameters
array$perpageoptionsThe available options for the number of data request to be displayed per page.

◆ show_hide_link()

tool_dataprivacy\output\data_requests_table::show_hide_link ( $column,
$index )
protected

Override the table's show_hide_link method to prevent the show/hide links from rendering.

Parameters
string$columnthe column name, index into various names.
int$indexnumerical index of the column.
Return values
stringHTML fragment.

The documentation for this class was generated from the following file: