22 lines
537 B
TypeScript
22 lines
537 B
TypeScript
import { SponsorDashboardDTO } from '@/lib/types/generated/SponsorDashboardDTO';
|
|
|
|
/**
|
|
* Sponsor Dashboard View Model
|
|
*
|
|
* Represents dashboard data for a sponsor with UI-specific transformations.
|
|
*/
|
|
export class SponsorDashboardViewModel {
|
|
sponsorId: string;
|
|
sponsorName: string;
|
|
|
|
constructor(dto: SponsorDashboardDTO) {
|
|
this.sponsorId = dto.sponsorId;
|
|
this.sponsorName = dto.sponsorName;
|
|
}
|
|
|
|
/** UI-specific: Welcome message */
|
|
get welcomeMessage(): string {
|
|
return `Welcome back, ${this.sponsorName}!`;
|
|
}
|
|
}
|