fix: align TypeScript types with backend referral schemas

- Add campaign_name field to ReferralEarning interface
- Fix telegram_id to number | null in TopReferrerItem (email-only users)
- Add email field to TopReferrerItem
This commit is contained in:
Fringg
2026-03-02 02:35:00 +03:00
parent 75a6149e2d
commit 11343f4f12
2 changed files with 3 additions and 1 deletions

View File

@@ -243,8 +243,9 @@ export interface DashboardStats {
export interface TopReferrerItem {
user_id: number;
telegram_id: number;
telegram_id: number | null;
username?: string;
email?: string | null;
display_name: string;
invited_count: number;
invited_today: number;

View File

@@ -17,6 +17,7 @@ interface ReferralEarning {
reason: string;
referral_username: string | null;
referral_first_name: string | null;
campaign_name: string | null;
created_at: string;
}