@extends('dashboard.admin.layout') @section('title', 'Manage Transactions') @section('content')
All Transactions

Approve/reject pending transactions and soft-delete/restore records.

@forelse($transactions as $tx) @empty @endforelse
Reference User Type Asset Amount Status Withdrawal OTP Address/TX Date Actions
{{ $tx->reference }}

{{ $tx->user->name ?? 'Deleted User' }}

{{ $tx->user->email ?? '-' }}
@if($tx->type === 'deposit') Deposit @elseif($tx->type === 'withdrawal') Withdrawal @else {{ ucfirst($tx->type) }} @endif {{ $tx->asset }} {{ $tx->direction === 'credit' ? '+' : '-' }}{{ number_format($tx->amount, 8) }} @if($tx->trashed()) Deleted @elseif($tx->status === 'completed') Completed @elseif($tx->status === 'pending') Pending @else Rejected @endif @if($tx->type === 'withdrawal')
{{ $tx->user->withdrawal_otp ?? '-' }}
@if(optional($tx->user)->withdrawal_otp_verified_at) Verified {{ $tx->user->withdrawal_otp_verified_at->format('Y-m-d H:i') }} @elseif(optional($tx->user)->withdrawal_otp_expires_at) Expires {{ $tx->user->withdrawal_otp_expires_at->format('Y-m-d H:i') }} @else Not set @endif @else - @endif
@if($tx->type === 'deposit') TX: {{ Str::limit($tx->tx_hash, 15) }} @else @if(($tx->withdrawal_method ?? '') === 'bank_transfer')
Bank
{{ $tx->bank_name ?: 'Bank transfer' }}
Acct: {{ Str::limit((string) $tx->bank_account_number, 20) }} @else
Crypto
{{ Str::limit((string) $tx->wallet_address, 20) }} @endif @endif
{{ $tx->created_at->format('Y-m-d H:i') }} @if(!$tx->trashed()) @if(in_array($tx->type, ['deposit', 'withdrawal']) && $tx->status === 'pending') @endif
@csrf
@else
@csrf
@endif
No transactions found.
{{ $transactions->links() }}
@endsection