refactor: migrate custom fields to transactions

refactor: extract functions to api domain

refactor: strict custom field parsing

refactor: remove rundown cache utilities

refactor: directory restructure
This commit is contained in:
Carlos Valente
2025-06-06 21:08:30 +02:00
committed by arc-alex
parent f3b4ea0155
commit 2498e59156
75 changed files with 2060 additions and 2480 deletions
@@ -1,4 +1,5 @@
import { SupportedEntry, OntimeEvent, OntimeDelay, OntimeBlock, Rundown } from 'ontime-types';
import { SupportedEntry, OntimeEvent, OntimeDelay, OntimeBlock, Rundown, CustomField } from 'ontime-types';
import { defaultRundown } from '../../../models/dataModel.js';
const baseEvent = {
@@ -46,6 +47,15 @@ export function makeRundown(patch: Partial<Rundown>): Rundown {
};
}
export function makeCustomField(patch: Partial<CustomField>): CustomField {
return {
type: 'string',
colour: '#000000',
label: 'Custom Field',
...patch,
};
}
/**
* Utility to generate a rundown of OntimeEvents form partial objects
*/