feat: admin panel - Settings, Categories, Payment Wallets, Seed/Clear data, User Balances
- Settings page: bot token (masked), admin IDs, commission config, WireGuard status - Categories page: CRUD with product count, delete guard - Payment Wallets page: commission wallets display, toggle, percentage - Users page: balance adjustment form (total_balance / bonus_balance) with audit log - Seed & Reset page: seed demo data (5 users, 10 products, 5 wallets, 5 purchases) and clear all data button with confirmation - Dashboard: flash messages for seed/clear success - Fixed seed.js: use dynamic IDs instead of hardcoded to avoid FK violations - Fixed seed.js: clear all tables before seeding to avoid UNIQUE constraints
This commit is contained in:
@@ -206,6 +206,30 @@ textarea { min-height: 80px; resize: vertical; }
|
||||
code { background: #f1f5f9; padding: 0.1rem 0.3rem; border-radius: 3px; font-size: 0.85em; }
|
||||
pre { font-size: 0.8rem; white-space: pre-wrap; word-break: break-all; max-width: 300px; }
|
||||
|
||||
.muted { color: var(--muted); font-size: 0.85rem; }
|
||||
|
||||
.settings-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
|
||||
gap: 1rem;
|
||||
}
|
||||
|
||||
.seed-card {
|
||||
background: var(--card);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius);
|
||||
padding: 1.5rem;
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
|
||||
.seed-card.danger {
|
||||
border-color: var(--danger);
|
||||
border-width: 2px;
|
||||
}
|
||||
|
||||
.seed-card h2 { margin-bottom: 0.5rem; }
|
||||
.seed-card p { margin-bottom: 1rem; color: var(--muted); }
|
||||
|
||||
@media (max-width: 640px) {
|
||||
.topnav { flex-direction: column; align-items: flex-start; }
|
||||
.logout-btn { margin-left: 0; }
|
||||
|
||||
Reference in New Issue
Block a user