@@ -9,10 +9,12 @@ import (
|
||||
// InventoryReportDownload returns the inventory report as an XLSX download.
|
||||
// @Summary Download inventory report
|
||||
// @Description Generates an inventory XLSX report and returns it as a file download.
|
||||
// @Description Requires Bearer authentication with the viewer role (admin also allowed).
|
||||
// @Tags reports
|
||||
// @Produce application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
|
||||
// @Success 200 {file} file "Inventory XLSX report"
|
||||
// @Failure 500 {object} models.ErrorResponse "Report generation failed"
|
||||
// @Security BearerAuth
|
||||
// @Router /api/report/inventory [get]
|
||||
func (h *Handler) InventoryReportDownload(w http.ResponseWriter, r *http.Request) {
|
||||
ctx, cancel := withRequestTimeout(r, reportRequestTimeout)
|
||||
@@ -38,10 +40,12 @@ func (h *Handler) InventoryReportDownload(w http.ResponseWriter, r *http.Request
|
||||
// UpdateReportDownload returns the updates report as an XLSX download.
|
||||
// @Summary Download updates report
|
||||
// @Description Generates an updates XLSX report and returns it as a file download.
|
||||
// @Description Requires Bearer authentication with the viewer role (admin also allowed).
|
||||
// @Tags reports
|
||||
// @Produce application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
|
||||
// @Success 200 {file} file "Updates XLSX report"
|
||||
// @Failure 500 {object} models.ErrorResponse "Report generation failed"
|
||||
// @Security BearerAuth
|
||||
// @Router /api/report/updates [get]
|
||||
func (h *Handler) UpdateReportDownload(w http.ResponseWriter, r *http.Request) {
|
||||
ctx, cancel := withRequestTimeout(r, reportRequestTimeout)
|
||||
|
||||
Reference in New Issue
Block a user