wip
This commit is contained in:
35
packages/racing/domain/entities/Team.ts
Normal file
35
packages/racing/domain/entities/Team.ts
Normal file
@@ -0,0 +1,35 @@
|
||||
/**
|
||||
* Domain Entities: Team, TeamMembership, TeamJoinRequest
|
||||
*
|
||||
* Extracted from racing-application teams module so that
|
||||
* team-related types live in the racing-domain package.
|
||||
*/
|
||||
|
||||
export type TeamRole = 'owner' | 'manager' | 'driver';
|
||||
export type TeamMembershipStatus = 'active' | 'pending' | 'none';
|
||||
|
||||
export interface Team {
|
||||
id: string;
|
||||
name: string;
|
||||
tag: string;
|
||||
description: string;
|
||||
ownerId: string;
|
||||
leagues: string[];
|
||||
createdAt: Date;
|
||||
}
|
||||
|
||||
export interface TeamMembership {
|
||||
teamId: string;
|
||||
driverId: string;
|
||||
role: TeamRole;
|
||||
status: TeamMembershipStatus;
|
||||
joinedAt: Date;
|
||||
}
|
||||
|
||||
export interface TeamJoinRequest {
|
||||
id: string;
|
||||
teamId: string;
|
||||
driverId: string;
|
||||
requestedAt: Date;
|
||||
message?: string;
|
||||
}
|
||||
Reference in New Issue
Block a user