@extends('layouts.app') @section('customcss') @endsection @section('content')

{{ __('Debtors & Creditors List') }}

Total Debtors

{{ $debtors->where('balance', '<', 0)->count() }}

Total Creditors

{{ $debtors->where('balance', '>', 0)->count() }}

Net Balance

{{ ($netBalance ?? 0) < 0 ? 'Owing' : 'Owed' }}

Total Accounts

Active
{{ __('Account Balances') }}
@forelse($debtors as $index => $debtor) @empty @endforelse
#
{{ __('Customer Name') }} {{ __('Contact') }} {{ __('Alt Contact') }} {{ __('Balance') }} {{ __('Status') }} {{ __('Actions') }}
{{ $index + 1 }}
{{ substr($debtor->name, 0, 1) }}
{{ $debtor->contact ?? '-' }} {{ $debtor->alt_contact ?? '-' }} {{ number_format($debtor->balance, 2) }} @if($debtor->balance < 0) {{ __('Debtor') }} @else {{ __('Creditor') }} @endif
{{ __('Sorry! No Result Found') }}

{{ __('No debtors or creditors found with current filters.') }}

{{ __('TOTALS:') }}
{{ __('Debtors:') }} {{ number_format(abs($totalDebit ?? 0), 2) }}
{{ __('Creditors:') }} {{ number_format($totalCredit ?? 0, 2) }}
{{ __('Net:') }} {{ number_format($netBalance ?? 0, 2) }}
@endsection @section('customjs') @endsection