@extends('layouts.main') @section('content')

Riwayat Penarikan Dana

@php($userTop = auth()->user()) @php($userTop = auth()->user()) @if(!$userTop || !$userTop->isSuperAdmin())
Saldo Saat Ini
Rp {{ number_format($stats['total_amount'] ?? 0, 0, ',', '.') }}
Berdasarkan pembayaran yang disetujui
@if($userTop && ($userTop->isAdmin() || $userTop->isCreator()))
@endif
@endif @if(session('success'))
{{ session('success') }}
@endif @if(session('error'))
{{ session('error') }}
@endif
@forelse($withdrawals as $w) @empty @endforelse
Tanggal User Nominal Status Bukti Diverifikasi Oleh Aksi
{{ optional($w->created_at)->format('d/m/Y H:i') }} {{ $w->user->name ?? 'User' }} Rp {{ number_format($w->amount, 0, ',', '.') }} @php($statusColor = match($w->status){ 'approved' => 'bg-green-100 text-green-800', 'rejected' => 'bg-red-100 text-red-800', 'paid' => 'bg-teal-100 text-teal-800', default => 'bg-yellow-100 text-yellow-800' }) {{ ucfirst($w->status) }} @php( $proofPath = null ) @if(!empty($w->notes)) @php( preg_match('/Bukti\s+transfer:\s*(.+)$/', $w->notes, $m) ) @if(!empty($m[1])) @php($proofPath = trim($m[1])) @endif @endif @if($proofPath) @else {{ $w->notes ?? '-' }} @endif {{ $w->verifier->name ?? '-' }} @php($currentUser = auth()->user()) @if($currentUser && ($currentUser->isAdmin() || $currentUser->isSuperAdmin())) @if(in_array($w->status, ['pending','proses'])) @else @endif @else Detail @endif
Belum ada riwayat penarikan.
{{ $withdrawals->links() }}
@endsection @push('scripts') @endpush