Tracking: Fix report names BT#17817

webservicelpcreate
Julio Montoya 5 years ago committed by admin beeznest
parent 4f82265068
commit 9701c3bf61
  1. 8
      main/mySpace/session.php

@ -255,14 +255,16 @@ switch ($action) {
@$pdf = new PDF('A4', $params['orientation'], $params); @$pdf = new PDF('A4', $params['orientation'], $params);
$pdf->setBackground($tpl->theme); $pdf->setBackground($tpl->theme);
$mode = 'D'; $mode = 'D';
$pdfName = $sessionInfo['name'].'_'.$studentInfo['complete_name'];
if ($allStudents) { if ($allStudents) {
$mode = 'F'; $mode = 'F';
$pdfName = $studentInfo['complete_name'];
} }
$result = @$pdf->content_to_pdf( $result = @$pdf->content_to_pdf(
$content, $content,
'', '',
'', $pdfName,
null, null,
$mode, $mode,
false, false,
@ -289,7 +291,7 @@ switch ($action) {
api_get_path(SYS_ARCHIVE_PATH) api_get_path(SYS_ARCHIVE_PATH)
); );
} }
$name = 'session-report'.api_get_utc_datetime().'.zip'; $name = $sessionInfo['name'].'_'.api_get_utc_datetime().'.zip';
$result = DocumentManager::file_send_for_download($tempZipFile, true, $name); $result = DocumentManager::file_send_for_download($tempZipFile, true, $name);
exit; exit;
break; break;

Loading…
Cancel
Save