Minor - adding session info see BT#8814

1.9.x
Julio Montoya 11 years ago
parent 037ec90c68
commit b104f04d4c
  1. 11
      main/inc/lib/attendance.lib.php
  2. 8
      main/template/default/export/table_pdf.tpl

@ -1666,7 +1666,7 @@ class Attendance
); );
$row++; $row++;
} }
$table->setColAttributes(0, array('style' => 'width:30%')); $table->setColAttributes(0, array('style' => 'width:28%'));
$row = 1; $row = 1;
foreach ($users as $user) { foreach ($users as $user) {
@ -1679,15 +1679,16 @@ class Attendance
$row++; $row++;
} }
$tableToString = null; //$tableToString = null;
//$sessionInfo = api_get_session_info(api_get_session_id()); //$sessionInfo = api_get_session_info(api_get_session_id());
//if (!empty($sessionInfo)) { //if (!empty($sessionInfo)) {
$tableToString .= '<strong>'.get_lang('PeriodToDisplay').'</strong>: '. /*$tableToString .= '<strong>'.get_lang('PeriodToDisplay').'</strong>: '.
sprintf(get_lang('FromDateXToDateY'), $startDate, $endDate); sprintf(get_lang('FromDateXToDateY'), $startDate, $endDate);*/
//} //}
$tableToString .= $table->toHtml(); $tableToString = $table->toHtml();
$params = array( $params = array(
'filename' => get_lang('Attendance') . '_' . api_get_utc_datetime(), 'filename' => get_lang('Attendance') . '_' . api_get_utc_datetime(),
'pdf_title' => get_lang('Attendance'), 'pdf_title' => get_lang('Attendance'),

@ -26,6 +26,14 @@
</td> </td>
{% endif %} {% endif %}
</tr> </tr>
{% if pdf_session_info.date_start != '0000-00-00' and pdf_session_info.date_end != '0000-00-00' %}
<tr>
<td>
<strong>{{ "PeriodToDisplay" | get_lang }}:</strong> {{ "FromDateXToDateY"| get_lang | format(pdf_session_info.date_start, pdf_session_info.date_end ) }}
</td>
</tr>
{% endif %}
{% endif %} {% endif %}
{% if pdf_course_info %} {% if pdf_course_info %}

Loading…
Cancel
Save