wip league admin tools
This commit is contained in:
@@ -36,13 +36,13 @@ export class RacesPageDataPresenter {
|
||||
track: race.track,
|
||||
car: race.car,
|
||||
scheduledAt: race.scheduledAt.toISOString(),
|
||||
status: race.status,
|
||||
status: race.status.toString(),
|
||||
leagueId: race.leagueId,
|
||||
leagueName,
|
||||
strengthOfField: race.strengthOfField ?? null,
|
||||
strengthOfField: race.strengthOfField?.toNumber() ?? null,
|
||||
isUpcoming: race.scheduledAt > new Date(),
|
||||
isLive: race.status === 'running',
|
||||
isPast: race.scheduledAt < new Date() && race.status === 'completed',
|
||||
isLive: race.status.isRunning(),
|
||||
isPast: race.scheduledAt < new Date() && race.status.isCompleted(),
|
||||
}));
|
||||
|
||||
this.model = { races } as RacesPageDataDTO;
|
||||
|
||||
Reference in New Issue
Block a user