import { ApiProperty } from '@nestjs/swagger'; export type AllRacesStatus = 'scheduled' | 'running' | 'completed' | 'cancelled' | 'all'; export class AllRacesListItemDTO { @ApiProperty() id!: string; @ApiProperty() track!: string; @ApiProperty() car!: string; @ApiProperty() scheduledAt!: string; @ApiProperty() status!: 'scheduled' | 'running' | 'completed' | 'cancelled'; @ApiProperty() leagueId!: string; @ApiProperty() leagueName!: string; @ApiProperty({ nullable: true }) strengthOfField!: number | null; } export class AllRacesFilterOptionsDTO { @ApiProperty({ type: [{ value: String, label: String }] }) statuses!: { value: AllRacesStatus; label: string }[]; @ApiProperty({ type: [{ id: String, name: String }] }) leagues!: { id: string; name: string }[]; } export class AllRacesPageDTO { @ApiProperty({ type: [AllRacesListItemDTO] }) races!: AllRacesListItemDTO[]; @ApiProperty({ type: AllRacesFilterOptionsDTO }) filters!: AllRacesFilterOptionsDTO; }