Cache available report templates
The available PDF report templates are loaded from the server when you click “Generate PDF” button.
Implement a new functional component that:
- checks Redux state if templates for this type exist, otherwise fetch them. Also re-fetch if the results are older than 5min.
- show "Generate PDF" button only if there are any templates.
- On click, display the dialog