{{-- Summary Cards --}}
Total Transactions
{{ $transactions->total() ?? $transactions->count() }}
Total Paid
₹{{ number_format( ($transactions instanceof \Illuminate\Pagination\AbstractPaginator) ? $transactions->getCollection()->sum(fn($t) => (float)($t->transation_amount ?? 0)) : $transactions->sum(fn($t) => (float)($t->transation_amount ?? 0)), 2 ) }}
(current page sum)
@php $today = \Carbon\Carbon::now()->toDateString(); $statusText = 'Not Subscribed'; $statusClass = 'bg-soft-secondary text-secondary'; if ($store->subcription === 'free-trial') { $statusText = 'Free Trial'; $statusClass = 'bg-soft-warning text-warning'; } elseif ($store->subcription === 'premium' && $store->premium_expire_date >= $today) { $statusText = 'Premium'; $statusClass = 'bg-soft-success text-success'; } elseif ($store->subcription === 'premium' && $store->premium_expire_date < $today) { $statusText = 'Expired'; $statusClass = 'bg-soft-danger text-danger'; } @endphp
Current Status
{{ $statusText }}
Expiry: {{ $store->premium_expire_date ?? '—' }}
{{-- Transactions Table --}}
{{-- Top Controls --}}
Showing latest transactions
{{-- Quick Search (client-side) --}}
@forelse($transactions as $index => $t) @php $amount = (float)($t->transation_amount ?? 0); $amountClass = $amount > 0 ? 'text-success' : 'text-muted'; $remark = $t->remark ?? '—'; @endphp @empty @endforelse
# Date Remark Amount
{{ ($transactions instanceof \Illuminate\Pagination\AbstractPaginator) ? $transactions->firstItem() + $index : $index + 1 }}
{{ $t->created_on ?? ($t->created_at ? $t->created_at->format('Y-m-d') : '—') }}
{{ $t->created_at ? $t->created_at->format('h:i A') : '' }}
{{ $remark }}
Txn ID: #{{ $t->id }}
₹{{ number_format($amount, 2) }}
@if($amount == 0 && strtolower($remark) === 'free trial') Trial @endif
No transactions found for this store.
{{-- Pagination --}} @if($transactions instanceof \Illuminate\Pagination\AbstractPaginator)
{{ $transactions->links() }}
@endif