This commit is contained in:
2025-12-16 21:44:20 +01:00
parent 7532c7ed6d
commit 8c67081953
38 changed files with 818 additions and 1321 deletions

View File

@@ -0,0 +1,12 @@
import type { PenaltyType } from '../../domain/entities/Penalty';
export interface ApplyPenaltyCommand {
raceId: string;
driverId: string;
stewardId: string;
type: PenaltyType;
value?: number;
reason: string;
protestId?: string;
notes?: string;
}

View File

@@ -0,0 +1,4 @@
export interface ApproveLeagueJoinRequestUseCaseParams {
leagueId: string;
requestId: string;
}

View File

@@ -0,0 +1,9 @@
/**
* Command for closing race event stewarding.
*
* Scheduled job that checks for race events with expired stewarding windows
* and closes them, triggering final results notifications.
*/
export interface CloseRaceEventStewardingCommand {
// No parameters needed - finds all expired events automatically
}

View File

@@ -0,0 +1,9 @@
export interface CompleteDriverOnboardingCommand {
userId: string;
firstName: string;
lastName: string;
displayName: string;
country: string;
timezone?: string;
bio?: string;
}

View File

@@ -0,0 +1,21 @@
import type { LeagueVisibilityInput } from './LeagueVisibilityInput';
export interface CreateLeagueWithSeasonAndScoringCommand {
name: string;
description?: string;
/**
* League visibility/ranking mode.
* - 'ranked' (or legacy 'public'): Competitive, public, affects ratings. Requires min 10 drivers.
* - 'unranked' (or legacy 'private'): Casual with friends, no rating impact.
*/
visibility: LeagueVisibilityInput;
ownerId: string;
gameId: string;
maxDrivers?: number;
maxTeams?: number;
enableDriverChampionship: boolean;
enableTeamChampionship: boolean;
enableNationsChampionship: boolean;
enableTrophyChampionship: boolean;
scoringPresetId?: string;
}

View File

@@ -0,0 +1,6 @@
export interface CreateSponsorCommand {
name: string;
contactEmail: string;
websiteUrl?: string;
logoUrl?: string;
}

View File

@@ -0,0 +1,3 @@
export interface DashboardOverviewParams {
driverId: string;
}

View File

@@ -0,0 +1,10 @@
import type { ProtestIncident } from '../../domain/entities/Protest';
export interface FileProtestCommand {
raceId: string;
protestingDriverId: string;
accusedDriverId: string;
incident: ProtestIncident;
comment?: string;
proofVideoUrl?: string;
}

View File

@@ -0,0 +1,6 @@
/**
* League visibility/ranking mode.
* - 'ranked' (or legacy 'public'): Competitive, public, affects driver ratings. Min 10 drivers.
* - 'unranked' (or legacy 'private'): Casual with friends, no rating impact.
*/
export type LeagueVisibilityInput = 'ranked' | 'unranked' | 'public' | 'private';