update user info page
This commit is contained in:
parent
a575f75faf
commit
4aebb4e41b
@ -54,6 +54,7 @@ export default class UserHandler {
|
||||
├ Total Purchases: ${userStats.purchase_count || 0}
|
||||
├ Total Spent: $${userStats.total_spent || 0}
|
||||
├ Active Wallets: ${userStats.crypto_wallet_count || 0}
|
||||
├ Archived Wallets: ${userStats.archived_wallet_count || 0}
|
||||
├ Bonus Balance: $${userStats.bonus_balance || 0}
|
||||
└ Total Balance: $${(userStats.total_balance || 0) + (userStats.bonus_balance || 0)}
|
||||
|
||||
|
@ -37,8 +37,8 @@ class UserService {
|
||||
COUNT(DISTINCT cw2.id) as archived_wallet_count
|
||||
FROM users u
|
||||
LEFT JOIN purchases p ON u.id = p.user_id
|
||||
LEFT JOIN crypto_wallets cw ON u.id = cw.user_id AND cw.wallet_type NOT LIKE '%_%'
|
||||
LEFT JOIN crypto_wallets cw2 ON u.id = cw2.user_id AND cw2.wallet_type LIKE '%_%'
|
||||
LEFT JOIN crypto_wallets cw ON u.id = cw.user_id AND cw.wallet_type NOT LIKE '%#_%' ESCAPE '#'
|
||||
LEFT JOIN crypto_wallets cw2 ON u.id = cw2.user_id AND cw2.wallet_type LIKE '%#_%' ESCAPE '#'
|
||||
WHERE u.telegram_id = ?
|
||||
GROUP BY u.id
|
||||
`, [telegramId.toString()]);
|
||||
|
Loading…
Reference in New Issue
Block a user