|
@ -898,7 +898,6 @@ class mod_attendance_renderer extends plugin_renderer_base { |
|
|
$table->align[] = 'center'; |
|
|
$table->align[] = 'center'; |
|
|
$table->size[] = '1px'; |
|
|
$table->size[] = '1px'; |
|
|
|
|
|
|
|
|
if (!empty($reportdata->att->grade)) { |
|
|
|
|
|
$table->head[] = get_string('points', 'attendance'); |
|
|
$table->head[] = get_string('points', 'attendance'); |
|
|
$table->align[] = 'center'; |
|
|
$table->align[] = 'center'; |
|
|
$table->size[] = '1px'; |
|
|
$table->size[] = '1px'; |
|
@ -906,14 +905,12 @@ class mod_attendance_renderer extends plugin_renderer_base { |
|
|
$table->head[] = get_string('percentage', 'attendance'); |
|
|
$table->head[] = get_string('percentage', 'attendance'); |
|
|
$table->align[] = 'center'; |
|
|
$table->align[] = 'center'; |
|
|
$table->size[] = '1px'; |
|
|
$table->size[] = '1px'; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if ($reportdata->pageparams->view == ATT_VIEW_SUMMARY) { |
|
|
if ($reportdata->pageparams->view == ATT_VIEW_SUMMARY) { |
|
|
$table->head[] = get_string('sessionstotal', 'attendance'); |
|
|
$table->head[] = get_string('sessionstotal', 'attendance'); |
|
|
$table->align[] = 'center'; |
|
|
$table->align[] = 'center'; |
|
|
$table->size[] = '1px'; |
|
|
$table->size[] = '1px'; |
|
|
|
|
|
|
|
|
if (!empty($reportdata->att->grade)) { |
|
|
|
|
|
$table->head[] = get_string('pointsallsessions', 'attendance'); |
|
|
$table->head[] = get_string('pointsallsessions', 'attendance'); |
|
|
$table->align[] = 'center'; |
|
|
$table->align[] = 'center'; |
|
|
$table->size[] = '1px'; |
|
|
$table->size[] = '1px'; |
|
@ -930,7 +927,6 @@ class mod_attendance_renderer extends plugin_renderer_base { |
|
|
$table->align[] = 'center'; |
|
|
$table->align[] = 'center'; |
|
|
$table->size[] = '1px'; |
|
|
$table->size[] = '1px'; |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if ($bulkmessagecapability) { // Display the table header for bulk messaging. |
|
|
if ($bulkmessagecapability) { // Display the table header for bulk messaging. |
|
|
// The checkbox must have an id of cb_selector so that the JavaScript will pick it up. |
|
|
// The checkbox must have an id of cb_selector so that the JavaScript will pick it up. |
|
@ -953,15 +949,12 @@ class mod_attendance_renderer extends plugin_renderer_base { |
|
|
$usersummary = $reportdata->summary->get_taken_sessions_summary_for($user->id); |
|
|
$usersummary = $reportdata->summary->get_taken_sessions_summary_for($user->id); |
|
|
} |
|
|
} |
|
|
$row->cells[] = $usersummary->numtakensessions; |
|
|
$row->cells[] = $usersummary->numtakensessions; |
|
|
if (!empty($reportdata->att->grade)) { |
|
|
|
|
|
$row->cells[] = format_float($usersummary->takensessionspoints, 1, true, true) . ' / ' . |
|
|
$row->cells[] = format_float($usersummary->takensessionspoints, 1, true, true) . ' / ' . |
|
|
format_float($usersummary->takensessionsmaxpoints, 1, true, true); |
|
|
format_float($usersummary->takensessionsmaxpoints, 1, true, true); |
|
|
$row->cells[] = format_float($usersummary->takensessionspercentage * 100) . '%'; |
|
|
$row->cells[] = format_float($usersummary->takensessionspercentage * 100) . '%'; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if ($reportdata->pageparams->view == ATT_VIEW_SUMMARY) { |
|
|
if ($reportdata->pageparams->view == ATT_VIEW_SUMMARY) { |
|
|
$row->cells[] = $usersummary->numallsessions; |
|
|
$row->cells[] = $usersummary->numallsessions; |
|
|
if (!empty($reportdata->att->grade)) { |
|
|
|
|
|
$row->cells[] = format_float($usersummary->takensessionspoints, 1, true, true) . ' / ' . |
|
|
$row->cells[] = format_float($usersummary->takensessionspoints, 1, true, true) . ' / ' . |
|
|
format_float($usersummary->allsessionsmaxpoints, 1, true, true); |
|
|
format_float($usersummary->allsessionsmaxpoints, 1, true, true); |
|
|
$row->cells[] = format_float($usersummary->allsessionspercentage * 100) . '%'; |
|
|
$row->cells[] = format_float($usersummary->allsessionspercentage * 100) . '%'; |
|
@ -970,7 +963,6 @@ class mod_attendance_renderer extends plugin_renderer_base { |
|
|
format_float($usersummary->allsessionsmaxpoints, 1, true, true); |
|
|
format_float($usersummary->allsessionsmaxpoints, 1, true, true); |
|
|
$row->cells[] = format_float($usersummary->maxpossiblepercentage * 100) . '%'; |
|
|
$row->cells[] = format_float($usersummary->maxpossiblepercentage * 100) . '%'; |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if ($bulkmessagecapability) { // Create the checkbox for bulk messaging. |
|
|
if ($bulkmessagecapability) { // Create the checkbox for bulk messaging. |
|
|
$row->cells[] = html_writer::checkbox('user'.$user->id, 'on', false, '', |
|
|
$row->cells[] = html_writer::checkbox('user'.$user->id, 'on', false, '', |
|
|