diff --git a/apps/server/src/api-data/rundown/rundown.controller.ts b/apps/server/src/api-data/rundown/rundown.controller.ts index eae0bd4b41..0c196fc551 100644 --- a/apps/server/src/api-data/rundown/rundown.controller.ts +++ b/apps/server/src/api-data/rundown/rundown.controller.ts @@ -1,4 +1,11 @@ -import { ErrorResponse, MessageResponse, OntimeRundownEntry, RundownCached, RundownPaginated } from 'ontime-types'; +import { + ErrorResponse, + MessageResponse, + OntimeRundown, + OntimeRundownEntry, + RundownCached, + RundownPaginated, +} from 'ontime-types'; import { getErrorMessage } from 'ontime-utils'; import { Request, Response } from 'express'; @@ -21,6 +28,11 @@ import { getRundown, } from '../../services/rundown-service/rundownUtils.js'; +export async function rundownGetAll(_req: Request, res: Response) { + const rundown = getRundown(); + res.json(rundown); +} + export async function rundownGetNormalised(_req: Request, res: Response) { const cachedRundown = getNormalisedRundown(); res.json(cachedRundown); diff --git a/apps/server/src/api-data/rundown/rundown.router.ts b/apps/server/src/api-data/rundown/rundown.router.ts index e8f1f59707..ebac101cbe 100644 --- a/apps/server/src/api-data/rundown/rundown.router.ts +++ b/apps/server/src/api-data/rundown/rundown.router.ts @@ -5,6 +5,7 @@ import { rundownApplyDelay, rundownBatchPut, rundownDelete, + rundownGetAll, rundownGetById, rundownGetNormalised, rundownGetPaginated, @@ -26,7 +27,8 @@ import { export const router = express.Router(); -router.get('/', rundownGetPaginatedQueryParams, rundownGetPaginated); // not used in Ontime frontend +router.get('/', rundownGetAll); // not used in Ontime frontend +router.get('/paginated', rundownGetPaginatedQueryParams, rundownGetPaginated); // not used in Ontime frontend router.get('/normalised', rundownGetNormalised); router.get('/:eventId', paramsMustHaveEventId, rundownGetById); // not used in Ontime frontend