UNPKG

@ministryofjustice/hmpps-digital-prison-reporting-frontend

Version:

The Digital Prison Reporting Frontend contains templates and code to help display data effectively in UI applications.

25 lines (22 loc) 854 B
import { initCatalogue } from '../../../components/_catalogue/catalogue/utils.js'; import { initMyReports } from '../../../components/my-reports/utils.js'; class MyReportsCatalogueController { layoutPath; services; constructor(layoutPath, services) { this.layoutPath = layoutPath; this.services = services; } GET = async (req, res) => { const args = { res, req, services: this.services }; const catalogue = await initCatalogue(args); const myReportsData = await initMyReports(req, res, this.services, { maxRows: 10 }); res.render(`dpr/routes/journeys/my-reports-catalogue/view`, { layoutPath: this.layoutPath, catalogue, myReportsData, }); }; } export { MyReportsCatalogueController as default }; //# sourceMappingURL=controller.js.map