Exemplo n.º 1
0
        public async Task <IActionResult> CreateCertificateAsync(int invoiceId, [FromQuery] string language)
        {
            var stream = await _documentGenerationManager.CreateCertificateForInvoiceAsync(invoiceId, language);

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

            file.FileDownloadName = $"{invoiceId}_attest.pdf";
            return(file);
        }