Выгрузка маршрутов: в имени файла сокращённые типы заявок (до 7) и дата
Имя формирует бэкенд и отдаёт в Content-Disposition (он добавлен в экспонируемые заголовки CORS), фронт сохраняет файл под этим именем. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -69,9 +69,9 @@ public sealed class ReportsController(VacancyReportService vacancies, RouteExpor
|
||||
var file = result.Value;
|
||||
|
||||
var disposition = new ContentDispositionHeaderValue("attachment");
|
||||
disposition.SetHttpFileName(RouteExportWorkbook.FileName);
|
||||
disposition.SetHttpFileName(file.FileName);
|
||||
Response.Headers.ContentDisposition = disposition.ToString();
|
||||
|
||||
return File(file, XlsxContentType);
|
||||
return File(file.Content, XlsxContentType);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user