website refactor
This commit is contained in:
14
apps/website/lib/view-data/leagues/LeagueScheduleViewData.ts
Normal file
14
apps/website/lib/view-data/leagues/LeagueScheduleViewData.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
export interface LeagueScheduleViewData {
|
||||
leagueId: string;
|
||||
races: Array<{
|
||||
id: string;
|
||||
name: string;
|
||||
scheduledAt: string; // ISO string
|
||||
track?: string;
|
||||
car?: string;
|
||||
sessionType?: string;
|
||||
isPast: boolean;
|
||||
isUpcoming: boolean;
|
||||
status: 'scheduled' | 'completed';
|
||||
}>;
|
||||
}
|
||||
18
apps/website/lib/view-data/leagues/LeagueSettingsViewData.ts
Normal file
18
apps/website/lib/view-data/leagues/LeagueSettingsViewData.ts
Normal file
@@ -0,0 +1,18 @@
|
||||
export interface LeagueSettingsViewData {
|
||||
leagueId: string;
|
||||
league: {
|
||||
id: string;
|
||||
name: string;
|
||||
description: string;
|
||||
visibility: 'public' | 'private';
|
||||
ownerId: string;
|
||||
createdAt: string;
|
||||
updatedAt: string;
|
||||
};
|
||||
config: {
|
||||
maxDrivers: number;
|
||||
scoringPresetId: string;
|
||||
allowLateJoin: boolean;
|
||||
requireApproval: boolean;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
export interface LeagueSponsorshipsViewData {
|
||||
leagueId: string;
|
||||
league: {
|
||||
id: string;
|
||||
name: string;
|
||||
description: string;
|
||||
};
|
||||
sponsorshipSlots: Array<{
|
||||
id: string;
|
||||
name: string;
|
||||
description: string;
|
||||
price: number;
|
||||
currency: string;
|
||||
isAvailable: boolean;
|
||||
sponsoredBy?: {
|
||||
id: string;
|
||||
name: string;
|
||||
logoUrl?: string;
|
||||
};
|
||||
}>;
|
||||
sponsorshipRequests: Array<{
|
||||
id: string;
|
||||
slotId: string;
|
||||
sponsorId: string;
|
||||
sponsorName: string;
|
||||
requestedAt: string;
|
||||
status: 'pending' | 'approved' | 'rejected';
|
||||
}>;
|
||||
}
|
||||
13
apps/website/lib/view-data/leagues/LeagueWalletViewData.ts
Normal file
13
apps/website/lib/view-data/leagues/LeagueWalletViewData.ts
Normal file
@@ -0,0 +1,13 @@
|
||||
export interface LeagueWalletViewData {
|
||||
leagueId: string;
|
||||
balance: number;
|
||||
currency: string;
|
||||
transactions: Array<{
|
||||
id: string;
|
||||
type: 'deposit' | 'withdrawal' | 'sponsorship' | 'prize';
|
||||
amount: number;
|
||||
description: string;
|
||||
createdAt: string;
|
||||
status: 'completed' | 'pending' | 'failed';
|
||||
}>;
|
||||
}
|
||||
Reference in New Issue
Block a user