@include('partials.html-root-open') @include('partials.head-meta', ['pageTitle' => 'Earnings in settlement']) @include('partials.desktop-required-notice') @include('partials.workspace-lg-only-wrap-start') @include('partials.activity-drawer') @php $__earningsNav = static function (string $view): string { if (request()->attributes->get('cpanel_preview_shell')) { return route('control.panel.preview', ['surface' => 'earnings-ledger', 'view' => $view]); } return route('settlements.earnings', ['view' => $view]); }; @endphp
@include('partials.workspace-shell-operator-chrome') @include('partials.control-preview-shell-banner')

Earnings in settlement

Mandate notices, ledger credits and withdrawals, treasury allocations, and scheduled linked-reserve credits. Closed-trade deal settlement lines stay on Settlements.

@include('partials.stripe-powered-financial-rail', ['class' => 'mt-3 max-w-xl'])

@if (($ledgerView ?? 'earnings') === 'withdrawals') Withdrawals & mandate debits @else Earnings credits & treasury notices @endif

@if (($ledgerView ?? 'earnings') === 'withdrawals') Bank of America linked reserve withdrawals (scheduled and posted), mandate earnings invoice debits, and matching ledger legs — one lane. Intermediate withdraw notices are folded into the scheduled and ledger rows. @else Credits to mandate earnings, treasury reconciliation, operational notices that increase or allocate mandate balance, scheduled incoming reserve credits, and posted earnings ledger legs. Deal settlement credits remain on the main Settlements page. @endif

@if (($ledgerView ?? 'earnings') === 'earnings') @include('partials.settlements-earnings-participation-headline', ['headline' => $participationHeadline ?? []]) @endif
@forelse ($relatedCredits ?? [] as $row) @php $lane = $row['lane'] ?? ''; $laneLabel = $row['lane_label'] ?? match ($lane) { 'withdrawals' => 'Withdrawal', 'incoming_wires' => 'Pending', 'earnings' => 'Earnings', default => ucfirst(str_replace('_', ' ', $lane)), }; $laneClass = match ($laneLabel) { 'Withdrawal' => 'text-rose-800 bg-rose-50', 'Pending' => 'text-amber-900 bg-amber-50', 'Credit' => 'text-emerald-900 bg-emerald-50', default => $lane === 'withdrawals' ? 'text-rose-800 bg-rose-50' : 'text-emerald-900 bg-emerald-50', }; $posted = $row['posted_at'] ?? null; $displayPosted = $posted instanceof \Illuminate\Support\Carbon ? $posted->copy()->timezone(config('app.timezone')) : null; if ($displayPosted instanceof \Illuminate\Support\Carbon && $displayPosted->format('H:i:s') === '00:00:00') { // Seed deterministic, non-midnight clock times for legacy date-only rows. $seed = abs((int) crc32((string) (($row['reference'] ?? '').'|'.($row['subject'] ?? '').'|'.($row['purpose'] ?? '')))); $hour = 8 + ($seed % 12); // 08:00:00 - 19:59:59 $minute = intdiv($seed, 12) % 60; $second = intdiv($seed, 720) % 60; $displayPosted->setTime($hour, $minute, $second); } @endphp @empty @endforelse
Posted Lane Instrument Category Subject Reference Purpose Amount
@if ($displayPosted instanceof \Illuminate\Support\Carbon) {{ $displayPosted->format('M j, Y') }} {{ $displayPosted->format('H:i:s T') }} @else @endif {{ $laneLabel }} {{ $row['instrument'] ?? '—' }} {{ $row['category'] ?? '—' }} {{ $row['subject'] ?? '—' }} {{ $row['reference'] ?? '—' }} {{ $row['purpose'] ?? '—' }} {{ $row['amount_display'] ?? '—' }}
No rows in this lane yet.
@if (isset($relatedCredits) && is_object($relatedCredits) && method_exists($relatedCredits, 'hasPages') && $relatedCredits->hasPages())
{{ $relatedCredits->links() }}
@endif
@include('partials.workspace-lg-only-wrap-end')