Moodle APIs  3.8
Moodle 3.8.6 (Build: 20201109)
Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | List of all members
report_loglive_renderable Class Reference

Report loglive renderable class. More...

Inheritance diagram for report_loglive_renderable:
renderable

Public Member Functions

 __construct ($logreader="", $course=0, $url="", $date=0, $page=0, $perpage=100, $order="timecreated DESC")
 Constructor. More...
 
 get_readers ($nameonly=false)
 Get a list of enabled sql_reader objects/name. More...
 
 get_refresh_rate ()
 Get refresh rate of the live updates.
 
 get_table ($ajax=false)
 Setup table and return it. More...
 

Public Attributes

stdClass $course
 course record
 
int $date
 selected date from which records should be displayed
 
int $groupid
 group id
 
string $order
 order to sort
 
int $page
 page number
 
int $perpage
 perpage records to show
 
string $selectedlogreader = null
 selected log reader pluginname
 
report_loglive_table_log $tablelog
 table log which will be used for rendering logs
 
moodle_url $url
 url of report page
 
const CUTOFF = 3600
 @const int number of seconds to show logs from, by default.
 

Protected Member Functions

 set_refresh_rate ()
 Set refresh rate of the live updates.
 
 setup_filters ()
 Setup filters. More...
 
 setup_table ()
 Setup table log.
 
 setup_table_ajax ()
 Setup table log for ajax output.
 

Protected Attributes

core log manager $logmanager
 log manager
 
int $refresh = 60
 refresh rate in seconds
 

Detailed Description

Report loglive renderable class.

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

Constructor & Destructor Documentation

◆ __construct()

report_loglive_renderable::__construct (   $logreader = "",
  $course = 0,
  $url = "",
  $date = 0,
  $page = 0,
  $perpage = 100,
  $order = "timecreated DESC" 
)

Constructor.

Parameters
string$logreader(optional)reader pluginname from which logs will be fetched.
stdClass | int$course(optional) course record or id
moodle_url | string$url(optional) page url.
int$datedate (optional) from which records will be fetched.
int$page(optional) page number.
int$perpage(optional) number of records to show per page.
string$order(optional) sortorder of fetched records

Member Function Documentation

◆ get_readers()

report_loglive_renderable::get_readers (   $nameonly = false)

Get a list of enabled sql_reader objects/name.

Parameters
bool$nameonlyif true only reader names will be returned.
Return values
arraycore\log\sql_reader object or name.

◆ get_table()

report_loglive_renderable::get_table (   $ajax = false)

Setup table and return it.

Parameters
bool$ajaxIf set to true report_loglive_table_log_ajax is set instead of report_loglive_table_log.
Return values
report_loglive_table_log|report_loglive_table_log_ajaxtable object

◆ setup_filters()

report_loglive_renderable::setup_filters ( )
protected

Setup filters.

Return values
stdClassfilters

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