1. New Components- src/components/PaymentMethodCard.js - Displays individual payment method- src/components/AddPaymentMethodDialog.js - Stripe Elements dialog for adding cards- src/components/PaymentMethodsSection.js - Main payment methods UI- src/components/PasswordConfirmDialog.js - Admin password re-entry dialog- src/components/admin/AdminPaymentMethodsPanel.js - Admin panel for user payment methods2. Profile Integration (src/pages/Profile.js)- Replaced placeholder Payment Method section with PaymentMethodsSection3. Admin Integration (src/pages/admin/AdminUserView.js)- Added AdminPaymentMethodsPanel to user detail view

This commit is contained in:
Koncept Kit
2026-01-31 01:09:37 +07:00
parent 7152382dca
commit 5d085153f6
7 changed files with 1412 additions and 15 deletions

View File

@@ -12,6 +12,7 @@ import ConfirmationDialog from '../../components/ConfirmationDialog';
import ChangeRoleDialog from '../../components/ChangeRoleDialog';
import StatusBadge from '../../components/StatusBadge';
import TransactionHistory from '../../components/TransactionHistory';
import AdminPaymentMethodsPanel from '../../components/admin/AdminPaymentMethodsPanel';
const AdminUserView = () => {
const { userId } = useParams();
@@ -417,6 +418,14 @@ const AdminUserView = () => {
</div>
</Card>
{/* Payment Methods Panel */}
<div className="mb-8">
<AdminPaymentMethodsPanel
userId={userId}
userName={`${user.first_name} ${user.last_name}`}
/>
</div>
{/* Additional Details */}
<Card className="p-8 bg-background rounded-2xl border border-[var(--neutral-800)]">
<h2 className="text-2xl font-semibold text-[var(--purple-ink)] mb-6" style={{ fontFamily: "'Inter', sans-serif" }}>