Browse Source

fix php warning when no status set.

MOODLE_33_STABLE
Dan Marsden 8 years ago
parent
commit
8ccea71898
  1. 2
      renderer.php

2
renderer.php

@ -1047,7 +1047,7 @@ class mod_attendance_renderer extends plugin_renderer_base {
$row->cells[] = userdate($sess->sessdate, get_string('strftimedmyw', 'attendance')) . $row->cells[] = userdate($sess->sessdate, get_string('strftimedmyw', 'attendance')) .
" ". $this->construct_time($sess->sessdate, $sess->duration); " ". $this->construct_time($sess->sessdate, $sess->duration);
$row->cells[] = $sess->description; $row->cells[] = $sess->description;
if (isset($sess->statusid)) { if (!empty($sess->statusid)) {
$status = $userdata->statuses[$sess->statusid]; $status = $userdata->statuses[$sess->statusid];
$row->cells[] = $status->description; $row->cells[] = $status->description;
$row->cells[] = format_float($status->grade, 1, true, true) . ' / ' . $row->cells[] = format_float($status->grade, 1, true, true) . ' / ' .

Loading…
Cancel
Save