@extends('layouts.admin') @section('title','Payment Records') @section('page-title','π³ Payment Records') @section('styles') @endsection @section('content')
| Transaction ID | Date | Customer | Amount | Email / Phone | Type | Anonymous
Controls Wall of Fame visibility |
|---|---|---|---|---|---|---|
| {{ $d->donation_id }} | {{ $d->created_at->format('Y-m-d') }} |
@if($isAnon)
Anonymous
@else
@if($d->type === 'business')
{{ $d->business_name ?? $d->donor_name ?? 'Donor' }}
@else
{{ $d->donor_name ?? 'Donor' }}
@endif
@endif
@if($d->type === 'business' && $d->donor_name)
Contact: {{ $d->donor_name }}
@endif
|
${{ number_format($d->amount,2) }} |
@if($isAnon)
β
@else
@if($d->email)
π§ {{ $d->email }}
@endif
@if($d->contact)
π {{ $d->contact }}
@endif
@if(!$d->email && !$d->contact)
β
@endif
@endif
|
{{ ucfirst($d->type) }}@if($isAnon) Anonymous @endif |
{{-- Pure div-based toggle β no pseudo-elements --}}
{{ $isAnon ? 'Hidden' : 'Shown' }}
Shows as {{ $isAnon ? 'Anonymous' : $donorLabel }} on Wall of Fame
|
| No donations found | ||||||
| Invoice # | Date | Customer | Amount (ex GST) | GST (10%) | Total (inc GST) | Card | Status | Refunded | Action |
|---|---|---|---|---|---|---|---|---|---|
| {{ $p->invoice_no }} | {{ $p->created_at->format('Y-m-d') }} | {{ $p->customer_name }} | ${{ number_format($p->amount_ex_gst,2) }} | ${{ number_format($p->gst,2) }} | ${{ number_format($p->amount,2) }} | @if($p->card_brand) {{ ucfirst($p->card_brand) }} β’β’β’β’ {{ $p->card_last4 }} @else β @endif | {{ ucfirst(str_replace('_',' ',$p->status)) }} | ${{ number_format($p->refunded_amount,2) }} | @php $refundable = (float) $p->amount - (float) $p->refunded_amount; $userStatus = $p->user?->status; $userExists = $p->user !== null; $balanceDonated = (bool) ($p->balance_donated ?? false); $balanceWithdrawn = (bool) ($p->balance_withdrawn ?? false); $canRefund = $p->status !== 'refunded' && $p->payment_intent_id && $refundable > 0 && $userExists && $userStatus === 'active' && ! $balanceDonated && ! $balanceWithdrawn; @endphp @if($canRefund) @else @if($balanceDonated) Donated @elseif($balanceWithdrawn) Withdrawn @elseif(!$userExists) Account Deleted @elseif($userStatus === 'suspended') Account Suspended @elseif($p->status === 'refunded') Fully Refunded @else β @endif @endif |
| No prepayments found | |||||||||
Update the donor name shown on Wall of Fame. This will also set the donation as non-anonymous.