change the pdf filenames

This commit is contained in:
Ruidy 2024-03-20 17:15:52 +01:00
parent 873e957078
commit 83f2490870
No known key found for this signature in database
GPG key ID: E00F51288CB857CC

View file

@ -27,7 +27,7 @@ func handleCreateInvoicePdf(bs *booking.Service, ps *pdf.PdfService, hc *config.
if err != nil {
return err
}
return c.Attachment("tmp.pdf", "tmp.pdf")
return c.Attachment("tmp.pdf", fmt.Sprintf("VFNI-%s.pdf", b.InvoiceNumber(hc)))
}
}
@ -65,6 +65,6 @@ func handleCreateReportPdf(bs *booking.Service, ps *pdf.PdfService) echo.Handler
return err
}
return c.Attachment("tmp.pdf", "tmp.pdf")
return c.Attachment("tmp.pdf", fmt.Sprintf("VF-%02d-report.pdf", month))
}
}