mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-26 18:42:49 +00:00
87 lines
4.3 KiB
TypeScript
87 lines
4.3 KiB
TypeScript
import { ReportKey } from "../../seed/freight-permissions.registry";
|
|
import { revenueByCustomerReport } from "./definitions/revenue-by-customer.report";
|
|
import { agingReceivablesReport } from "./definitions/aging-receivables.report";
|
|
import { contractUtilizationReport } from "./definitions/contract-utilization.report";
|
|
import { wagonFleetStatusReport } from "./definitions/wagon-fleet-status.report";
|
|
import { wagonStatusDurationReport } from "./definitions/wagon-status-duration.report";
|
|
import { wagonRequestsReport } from "./definitions/wagon-requests.report";
|
|
import { locomotiveFleetStatusReport } from "./definitions/locomotive-fleet-status.report";
|
|
import { bookingStatusBreakdownReport } from "./definitions/booking-status-breakdown.report";
|
|
import { trainScheduleStatusReport } from "./definitions/train-schedule-status.report";
|
|
import { trainTurnaroundReport } from "./definitions/train-turnaround.report";
|
|
import { wagonTeuUtilizationReport } from "./definitions/wagon-teu-utilization.report";
|
|
import { loadedCapacityReport } from "./definitions/loaded-capacity.report";
|
|
import { globalLogisticsWagonsReport } from "./definitions/global-logistics-wagons.report";
|
|
import { customsDocumentsReport } from "./definitions/customs-documents.report";
|
|
import { invoicingPipelineReport } from "./definitions/invoicing-pipeline.report";
|
|
import { firstLastMileBookingsReport } from "./definitions/first-last-mile-bookings.report";
|
|
import { cargoSummaryReport } from "./definitions/cargo-summary.report";
|
|
import { revenueByCategoryReport } from "./definitions/revenue-by-category.report";
|
|
import { revenueTransactionsReport } from "./definitions/revenue-transactions.report";
|
|
import { revenueByPeriodReport } from "./definitions/revenue-by-period.report";
|
|
import { revenueByRouteReport } from "./definitions/revenue-by-route.report";
|
|
import { revenueTopCustomersReport } from "./definitions/revenue-top-customers.report";
|
|
import { paymentClassificationReport } from "./definitions/payment-classification.report";
|
|
import { revenueReconciliationReport } from "./definitions/revenue-reconciliation.report";
|
|
import { receivablesPayablesReport } from "./definitions/receivables-payables.report";
|
|
import { revenueAnomaliesReport } from "./definitions/revenue-anomalies.report";
|
|
import { stationStayingTimeReport } from "./definitions/station-staying-time.report";
|
|
import { turnaroundCycleReport } from "./definitions/turnaround-cycle.report";
|
|
import { trainDelaysReport } from "./definitions/train-delays.report";
|
|
import { trainsetPerformanceReport } from "./definitions/trainset-performance.report";
|
|
import { teuPerformanceReport } from "./definitions/teu-performance.report";
|
|
import { cargoVolumePerformanceReport } from "./definitions/cargo-volume-performance.report";
|
|
import { chargedVsActualVolumeReport } from "./definitions/charged-vs-actual-volume.report";
|
|
import { cargoVolumeByStationReport } from "./definitions/cargo-volume-by-station.report";
|
|
import { ReportDefinition } from "./report.types";
|
|
|
|
/**
|
|
* Every report the platform knows about. Adding one = a new file under
|
|
* definitions/ + a key in REPORT_KEYS (freight-permissions.registry.ts) +
|
|
* an entry here. Nothing else — no frontend edit, no route, no sidebar edit.
|
|
*/
|
|
export const REPORTS: ReportDefinition[] = [
|
|
revenueByCustomerReport,
|
|
agingReceivablesReport,
|
|
contractUtilizationReport,
|
|
wagonFleetStatusReport,
|
|
wagonStatusDurationReport,
|
|
wagonRequestsReport,
|
|
locomotiveFleetStatusReport,
|
|
bookingStatusBreakdownReport,
|
|
trainScheduleStatusReport,
|
|
trainTurnaroundReport,
|
|
wagonTeuUtilizationReport,
|
|
loadedCapacityReport,
|
|
globalLogisticsWagonsReport,
|
|
customsDocumentsReport,
|
|
invoicingPipelineReport,
|
|
firstLastMileBookingsReport,
|
|
cargoSummaryReport,
|
|
revenueByCategoryReport,
|
|
revenueTransactionsReport,
|
|
revenueByPeriodReport,
|
|
revenueByRouteReport,
|
|
revenueTopCustomersReport,
|
|
paymentClassificationReport,
|
|
revenueReconciliationReport,
|
|
receivablesPayablesReport,
|
|
revenueAnomaliesReport,
|
|
stationStayingTimeReport,
|
|
turnaroundCycleReport,
|
|
trainDelaysReport,
|
|
trainsetPerformanceReport,
|
|
teuPerformanceReport,
|
|
cargoVolumePerformanceReport,
|
|
chargedVsActualVolumeReport,
|
|
cargoVolumeByStationReport,
|
|
];
|
|
|
|
const BY_KEY = new Map<ReportKey, ReportDefinition>(
|
|
REPORTS.map((r) => [r.key, r]),
|
|
);
|
|
|
|
export function getReport(key: string): ReportDefinition | undefined {
|
|
return BY_KEY.get(key as ReportKey);
|
|
}
|