mirror of
https://github.com/chillpadclub/bedolaga-cabinet.git
synced 2026-07-28 17:43:47 +00:00
fix: show email for OAuth/email users in traffic table
Add email field to UserTrafficItem type and display it below user name when no Telegram username is present.
This commit is contained in:
@@ -10,6 +10,7 @@ export interface UserTrafficItem {
|
||||
user_id: number;
|
||||
telegram_id: number | null;
|
||||
username: string | null;
|
||||
email: string | null;
|
||||
full_name: string;
|
||||
tariff_name: string | null;
|
||||
subscription_status: string | null;
|
||||
|
||||
@@ -1381,11 +1381,15 @@ export default function AdminTrafficUsage() {
|
||||
</div>
|
||||
<div className="min-w-0">
|
||||
<div className="truncate text-xs font-medium text-dark-100">{item.full_name}</div>
|
||||
{item.username && (
|
||||
{item.username ? (
|
||||
<div className="truncate text-[10px] leading-tight text-dark-500">
|
||||
@{item.username}
|
||||
</div>
|
||||
)}
|
||||
) : item.email ? (
|
||||
<div className="truncate text-[10px] leading-tight text-dark-500">
|
||||
{item.email}
|
||||
</div>
|
||||
) : null}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user