@extends('root') @section('title', 'Balance') @push('styles') @endpush @section('content')
@include('components.breadcrumb', [ 'title' => 'Balance', 'links' => [ ['url' => route('client.dashboard'), 'label' => 'Dashboard'], ['url' => route('client.balance'), 'label' => 'Balance'], ], 'current' => 'Balance' ])
Saldo Saat Ini

Rp {{ number_format($client->balance, 0, ',', '.') }}

@if($transactions->isEmpty())

Belum ada transaksi topup

Topup Sekarang
@else
@foreach($transactions as $tx) @endforeach
Order ID Nominal Metode Status Tanggal Aksi
{{ Str::limit($tx->order_id, 20) }} {{ $tx->formatted_amount }} {{ $tx->payment_channel ?? 'N/A' }} @switch($tx->status) @case('SUCCESS') {{ $tx->status }} @break @case('PENDING') {{ $tx->status }} @break @case('EXPIRED') {{ $tx->status }} @break @default {{ $tx->status }} @endswitch {{ $tx->created_at->format('d M Y') }}
{{ $tx->created_at->format('H:i') }}
{{ $transactions->links('pagination::bootstrap-5') }}
@endif
@if($balanceHistories->isEmpty())

Belum ada riwayat saldo

@else
@foreach($balanceHistories as $history) @endforeach
Ref ID Tipe Nominal Saldo Tanggal Aksi
{{ Str::limit($history->reference_id, 15) }} @switch($history->type) @case('TOPUP') TOPUP @break @case('DEDUCTION') DEDUCTION @break @case('MANUAL') MANUAL @break @case('REFUND') REFUND @break @default {{ $history->type }} @endswitch {{ $history->formatted_amount }}
Rp {{ number_format($history->balance_before, 0, ',', '.') }} Rp {{ number_format($history->balance_after, 0, ',', '.') }}
{{ $history->created_at->format('d M Y') }}
{{ $history->created_at->format('H:i') }}
{{ $balanceHistories->links('pagination::bootstrap-5') }}
@endif
@endsection @push('scripts') @endpush