change scheduling mode to enum in rounds, change appreance of scheduling

mode picker in competition
This commit is contained in:
unurled 2025-07-07 22:51:37 +02:00
parent 592da87c26
commit 95d8988876
Signed by: unurled
GPG key ID: EFC5F5E709B47DDD
16 changed files with 159 additions and 115 deletions

View file

@ -20,3 +20,9 @@ export enum SchedulingMode {
round_robin = 'round_robin',
double_round_robin = 'double_round_robin'
}
export function enumToPgEnum<T extends Record<string, any>>(
myEnum: T
): [T[keyof T], ...T[keyof T][]] {
return Object.values(myEnum).map((value: any) => `${value}`) as any;
}