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.

96 lines (95 loc) 3.42 kB
import type { Response, Request } from 'express'; import { RequestedReport, StoredReportData } from '../types/UserReports'; import { BookmarkStoreData } from '../types/Bookmark'; export declare const getValues: (res: Response) => { csrfToken: string; definitions: { id: string; name: string; description?: string | null; variants: import("../..").components["schemas"]["VariantDefinitionSummary"][]; dashboards?: import("../..").components["schemas"]["DashboardDefinitionSummary"][] | null; authorised: boolean; }[]; bookmarkingEnabled: boolean; downloadingEnabled: boolean; saveDefaultsEnabled: boolean; subscriptionsEnabled: boolean; requestMissingEnabled: boolean; collectionsEnabled: boolean; definitionsPath: string; dpdPathFromQuery: boolean; dpdPathFromConfig: boolean; pathSuffix: any; requestedReports: RequestedReport[]; recentlyViewedReports: StoredReportData[]; bookmarks: BookmarkStoreData[]; subscriptions: StoredReportData[]; token: string; dprUser: { id: string; token: string; activeCaseLoadId: string | undefined; staffId: number | undefined; email: string; displayName: string; }; }; export declare const setDdpPathToReqQuery: (req: Request, value: string) => import("qs").ParsedQs; export interface DprAppLocals { nestedBaseUrl?: string | undefined; bookmarkActionEndpoint: string; subscribePath: string; downloadActionEndpoint: string; productCollectionEndpoint: string; bookmarkListPath: string; requestedListPath: string; recentlyViewedListPath: string; reportsCatalogue: string; userReportsList: string; dprHomepage: string; requestReportPath: string; viewReportPath: string; /** internal: stores the unmodified raw paths */ original?: Omit<DprAppLocals, 'original' | 'nestedBaseUrl'>; } export declare const getRouteLocals: (res: Response) => DprAppLocals; declare const _default: { getValues: (res: Response) => { csrfToken: string; definitions: { id: string; name: string; description?: string | null; variants: import("../..").components["schemas"]["VariantDefinitionSummary"][]; dashboards?: import("../..").components["schemas"]["DashboardDefinitionSummary"][] | null; authorised: boolean; }[]; bookmarkingEnabled: boolean; downloadingEnabled: boolean; saveDefaultsEnabled: boolean; subscriptionsEnabled: boolean; requestMissingEnabled: boolean; collectionsEnabled: boolean; definitionsPath: string; dpdPathFromQuery: boolean; dpdPathFromConfig: boolean; pathSuffix: any; requestedReports: RequestedReport[]; recentlyViewedReports: StoredReportData[]; bookmarks: BookmarkStoreData[]; subscriptions: StoredReportData[]; token: string; dprUser: { id: string; token: string; activeCaseLoadId: string | undefined; staffId: number | undefined; email: string; displayName: string; }; }; getRouteLocals: (res: Response) => DprAppLocals; setDdpPathToReqQuery: (req: Request, value: string) => import("qs").ParsedQs; }; export default _default;