@extends('layouts.app') @section('title', 'Statement — '.$customer->display_name) @section('content')
{{ $customer->display_name }} · {{ $customer->customer_number }} · {{ $from->format('d M Y') }} to {{ $to->format('d M Y') }}
| Date | Description | Reference | Debit | Credit | Balance | Status |
|---|---|---|---|---|---|---|
| {{ $row['date']->format('d M Y') }} | {{ $row['type'] }} | {{ $row['ref'] }} | {{ $row['debit'] > 0 ? money($row['debit'], $customer->currency) : '—' }} | {{ $row['credit'] > 0 ? money($row['credit'], $customer->currency) : '—' }} | {{ money($balance, $customer->currency) }} | {{ $row['status'] }} |
| @include('components.empty-state', ['icon' => '📄', 'title' => 'No transactions in this period']) | ||||||
| Closing balance | {{ money($invoices->sum('total'), $customer->currency) }} | {{ money($payments->sum('amount'), $customer->currency) }} | {{ money($balance, $customer->currency) }} | |||