Re-add code column (#264)
This commit is contained in:
parent
8ba89c18ce
commit
9df6c9d71e
1 changed files with 13 additions and 0 deletions
|
@ -74,6 +74,7 @@ class report_table extends \table_sql {
|
|||
$columns[] = $extrafield;
|
||||
}
|
||||
$columns[] = 'timecreated';
|
||||
$columns[] = 'code';
|
||||
|
||||
$headers = [];
|
||||
$headers[] = get_string('fullname');
|
||||
|
@ -81,6 +82,7 @@ class report_table extends \table_sql {
|
|||
$headers[] = get_user_field_name($extrafield);
|
||||
}
|
||||
$headers[] = get_string('receiveddate', 'customcert');
|
||||
$headers[] = get_string('code', 'customcert');
|
||||
|
||||
// Check if we were passed a filename, which means we want to download it.
|
||||
if ($download) {
|
||||
|
@ -101,6 +103,7 @@ class report_table extends \table_sql {
|
|||
$this->define_headers($headers);
|
||||
$this->collapsible(false);
|
||||
$this->sortable(true);
|
||||
$this->no_sorting('code');
|
||||
$this->no_sorting('download');
|
||||
$this->is_downloadable(true);
|
||||
|
||||
|
@ -135,6 +138,16 @@ class report_table extends \table_sql {
|
|||
return userdate($user->timecreated);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generate the code column.
|
||||
*
|
||||
* @param \stdClass $user
|
||||
* @return string
|
||||
*/
|
||||
public function col_code($user) {
|
||||
return $user->code;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generate the download column.
|
||||
*
|
||||
|
|
Loading…
Reference in a new issue