Export Bufdir Report in Required File Format
Once the coordinator confirms the preview is correct, they initiate the export. The system generates the file in the selected format using Bufdir's column schema, bundles any required attachments, logs the export event for audit, and stores the file in a dedicated storage bucket. The coordinator can then download the file directly to their device or share it via the platform's file sharing capabilities.
User Story
Acceptance Criteria
- Given the coordinator selects a file format (Excel, CSV, or PDF) and confirms export, when the export process runs, then a file is generated in the selected format with Bufdir's required column structure
- Given the file is generated, when the coordinator downloads it, then the file opens correctly in the corresponding application (Excel for .xlsx, spreadsheet viewer for .csv, PDF reader for .pdf)
- Given the export completes, when the coordinator checks report history, then a new entry appears with the correct period, timestamp, format, and metrics
- Given attachments are required for the submission period, when export runs, then the attachment bundler packages activity attachments alongside the main report file
- Given the export process fails mid-way, when the error occurs, then no partial file is saved, the error is logged with details, and the coordinator is prompted to retry
- Given the coordinator triggers export, when the file is uploaded to storage, then the export audit service logs the event with organisation ID, coordinator ID, period, and timestamp
Business Value
Bufdir's grant system requires submissions in specific formats. Generating compliant files automatically eliminates the manual formatting step that currently takes coordinators several hours per reporting cycle. Supporting all required formats (Excel, CSV, PDF) ensures compatibility regardless of which intake channel Bufdir uses, and the audit log satisfies both internal governance requirements and external auditor requests.
Components
- Bufdir Export Trigger Screen ui
- Bufdir Period Selector Widget ui
- Export Format Selector ui
- Export Confirmation Dialog ui
- Bufdir Export Orchestrator Service service
- Bufdir Activity Query Service service
- Bufdir Column Mapper service
- Document Attachment Bundler service
- Export Audit Log Service service
- Export Audit Log Repository data
- Excel / CSV File Generator infrastructure
- Bufdir PDF Report Generator infrastructure
- Export File Storage Adapter infrastructure
- File Download Handler infrastructure