@extends('adminlte::layouts.app') @section('htmlheader_title') Unapplied Payments @endsection @section('page_title') Unapplied @endsection @section('contentheader_title') Unapplied Payments @endsection @section('contentheader_description') @endsection @section('main-content')
@foreach(\App\Models\Payment::unapplied()->with(['account.user','checkout','items'])->get() as $o) @if (! $o->balance) @continue @endif @endforeach
ID Date Paid Account Method Total Balance Invoices
{{ $o->id }} {{ $o->paid_at->format('Y-m-d') }} {{ $o->account->name }} {{ $o->checkout->name }} {{ number_format($o->total_amt,2) }} {{ number_format($o->balance,2) }} {!! $o->items->pluck('invoice_id')->map(function($item) { return sprintf('%d',url('u/invoice',$item),$item); })->join(', ') !!}
@endsection @section('page-scripts') @css(datatables,bootstrap4) @js(datatables,bootstrap4) @append