|
| __construct ($courseid, $gpr, $context, $userid, $viewasuser=null) |
| Constructor. More...
|
|
| calculate_averages () |
| Builds the grade item averages.
|
|
| fill_contributions_column ($element) |
| This function is called after the table has been built and the aggregationhints have been collected. More...
|
|
| fill_table () |
|
| get_lang_string ($strcode, $section=null) |
| First checks the cached language strings, then returns match if found, or uses get_string() to get it from the DB, caches it then returns it. More...
|
|
| get_numusers ($groups=true, $users=false) |
| Fetches and returns a count of all the users that will be shown on this page. More...
|
|
| get_pref ($pref, $objectid=null) |
| Given the name of a user preference (without grade_report_ prefix), locally saves then returns the value of that preference. More...
|
|
| inject_rowspans (&$element) |
| Recurses through a tree of elements setting the rowspan property on each element. More...
|
|
| print_table ($return=false) |
| Prints or returns the HTML from the flexitable. More...
|
|
| process_action ($target, $action) |
| Processes a single action against a category, grade_item or grade. More...
|
|
array | process_data ($data) |
| Processes the data sent by the form (grades and feedbacks). More...
|
|
| set_pref ($pref, $pref_value='default', $itemid=null) |
| Uses set_user_preferences() to update the value of a user preference. More...
|
|
| setup_table () |
| Prepares the headers and attributes of the flexitable.
|
|
| setup_users () |
| Sets up this report's user criteria to restrict the selection of users to display.
|
|
| viewed () |
| Trigger the grade_report_viewed event. More...
|
|
|
| $baseurl |
|
| $canviewhidden |
|
context | $context |
| The context. More...
|
|
object | $course |
| The course. More...
|
|
int | $courseid |
| The courseid. More...
|
|
int | $currentgroup |
| The current group being displayed. More...
|
|
string | $currentgroupname |
| The current groupname being displayed. More...
|
|
int | $decimals = 2 |
| Decimal points to use for values in the report, default 2.
|
|
| $evenodd |
|
object | $gpr |
| Grade plugin return tracking object. More...
|
|
string | $gradebookroles |
| The roles for this report. More...
|
|
array | $gradeitemsdata = array() |
| An array containing the grade items data for external usage (web services, ajax, etc...)
|
|
string | $group_selector |
| A HTML select element used to select the current group. More...
|
|
int | $groupmode |
| Current course group mode $groupmode.
|
|
| $gseq |
| Flat structure similar to grade tree.
|
|
grade_tree | $gtree |
| The grade tree structure.
|
|
array | $lang_strings = array() |
| Array of cached language strings (using get_string() all the time takes a long time!). More...
|
|
| $maxdepth |
|
int | $page |
| Current page (for paging). More...
|
|
| $pbarurl |
|
array | $prefs = array() |
| User preferences related to this report. More...
|
|
int | $rangedecimals = 0 |
| The number of decimal places to round range to, default 0.
|
|
false | $showaverage = false |
| Show average grades in the report, default false.
|
|
bool | $showcontributiontocoursetotal = true |
| Show the calculated contribution to the course total column.
|
|
bool | $showfeedback = true |
| Show grade feedback in the report, default true.
|
|
bool | $showgrade = true |
| Show grades in the report, default true.
|
|
| $showhiddenitems |
| Show hidden items even when user does not have required cap.
|
|
bool | $showlettergrade = false |
| Show letter grades in the report, default false.
|
|
| $showpercentage |
| show grade percentages
|
|
| $showrange = true |
| Show range.
|
|
| $showrank |
| show student ranks
|
|
| $showtotalsifcontainhidden |
|
bool | $showweight = true |
| Show grade weighting in the report, default true.
|
|
| $switch |
|
object | $table |
| A flexitable to hold the data. More...
|
|
array | $tablecolumns = array() |
| An array of table columns.
|
|
type | $tabledata = array() |
| An array containing rows of data for the table.
|
|
array | $tableheaders = array() |
| An array of table headers.
|
|
object | $user |
| The user. More...
|
|
|
| blank_hidden_total ($courseid, $course_item, $finalgrade) |
| Optionally blank out course/category totals if they contain any hidden items. More...
|
|
| blank_hidden_total_and_adjust_bounds ($courseid, $course_item, $finalgrade) |
| Optionally blank out course/category totals if they contain any hidden items. More...
|
|
| get_sort_arrow ($direction='move', $sortlink=null) |
| Returns an arrow icon inside an tag, for the purpose of sorting a column. More...
|
|
| setup_groups () |
| Sets up this object's group variables, mainly to restrict the selection of users to display.
|
|
|
array | $aggregationhints = array() |
| An array that collects the aggregationhints for every grade_item. More...
|
|
string | $groupsql |
| An SQL fragment used to add linking information to the group tables. More...
|
|
string | $groupwheresql |
| An SQL constraint to append to the queries used by this object to build the report. More...
|
|
array | $groupwheresql_params = array() |
| The ordered params for $groupwheresql $groupwheresql_params.
|
|
course_modinfo | $modinfo = null |
| The modinfo object to be used.
|
|
string | $userwheresql |
| An SQL constraint to append to the queries used by this object to build the report. More...
|
|
array | $userwheresql_params = array() |
| The ordered params for $userwheresql $userwheresql_params.
|
|
boolean | $viewasuser = false |
| View as user. More...
|
|
Class providing an API for the user report building and displaying.
@uses grade_report
grade_report::get_pref |
( |
|
$pref, |
|
|
|
$objectid = null |
|
) |
| |
|
inherited |
Given the name of a user preference (without grade_report_ prefix), locally saves then returns the value of that preference.
If the preference has already been fetched before, the saved value is returned. If the preference is not set at the User level, the $CFG equivalent is given (site default). Can be called statically, but then doesn't benefit from caching
- Parameters
-
string | $pref | The name of the preference (do not include the grade_report_ prefix) |
int | $objectid | An optional itemid or categoryid to check for a more fine-grained preference |
- Return values
-
mixed | The value of the preference |