update file name

This commit is contained in:
Simon Vieille 2020-04-29 19:51:01 +02:00
parent e7b7e07d98
commit 9ec4ca6050
Signed by: deblan
GPG key ID: 03383D15A1D31745

View file

@ -53,7 +53,7 @@ class EventController extends AbstractController
return new BinaryFileResponse($src, 200, [
'Content-Type' => 'application/octect-stream',
'Content-Length' => filesize($src),
'Content-Disposition' => sprintf('attachment; filename="%s"', basename($src)),
'Content-Disposition' => sprintf('attachment; filename="%s_%s"', $snapshot->getDate()->format('Y-m-d'), basename($src)),
'Content-Transfer-Encoding' => 'binary',
]);
}