Exemplo n.º 1
0
        public async Task <IActionResult> DownloadInvoiceDocumentAsync(int invoiceId)
        {
            var fileStream = await _documentGenerationManager.DownloadInvoiceDocumentAsync(invoiceId);

            var file = new FileStreamResult(fileStream, "application/pdf");

            file.FileDownloadName = fileStream.Name;
            return(file);
        }