{{-- ========================================================= --}} {{-- MESSAGE --}} {{-- ========================================================= --}} @if (session()->has('success'))
{{ session('success') }}
@endif {{-- ========================================================= --}} {{-- EN-TÊTE --}} {{-- ========================================================= --}}

Comptes clients

Gérez les comptes de dépôt de vos clients.

{{-- Nouveau client --}} {{-- Liste des clients --}} {{-- Nouveau compte --}} @can('deposits.create') @endcan
{{-- ========================================================= --}} {{-- STATISTIQUES --}} {{-- ========================================================= --}}
{{-- Total comptes --}}
Total comptes

{{ number_format($totalAccounts, 0, ',', ' ') }}

{{-- Comptes actifs --}}
Comptes actifs

{{ number_format($activeAccounts, 0, ',', ' ') }}

{{-- Total dépôts --}}
Total dépôts

{{ $this->formatMoney($totalDeposits) }}

{{-- Solde clients --}}
Solde clients

{{ $this->formatMoney($totalBalance) }}

{{-- ========================================================= --}} {{-- FILTRES --}} {{-- ========================================================= --}}
{{-- ========================================================= --}} {{-- TABLEAU --}} {{-- ========================================================= --}}
@if($accounts->count() > 0) @foreach ($accounts as $account) @php $totalDeposit = (float) ($account->total_deposits ?? 0); $totalWithdrawal = (float) ($account->total_withdrawals ?? 0); $balance = $totalDeposit - $totalWithdrawal; @endphp {{-- Client --}} {{-- Numéro compte --}} {{-- Dépôts --}} {{-- Retraits --}} {{-- Solde --}} {{-- Statut --}} {{-- Actions --}} @endforeach @else @endif
Client Compte Total dépôt Total retrait Solde Statut Actions
{{ $account->client->name }}
@if ($account->client->phone) {{ $account->client->phone }} @endif
{{ $account->account_number }} {{ $this->formatMoney($totalDeposit) }} {{ $this->formatMoney($totalWithdrawal) }} {{ $this->formatMoney($balance) }} @if ($account->is_active) Actif @else Inactif @endif @can('deposits.edit') @endcan
Aucun compte de dépôt
Aucun compte client ne correspond aux critères sélectionnés.
@if ($accounts->hasPages()) @endif
{{-- ========================================================= --}} {{-- MODAL NOUVEAU COMPTE --}} {{-- ========================================================= --}} @if ($showModal) @endif {{-- ===================================================================== --}} {{-- MODAL NOUVEAU CLIENT --}} {{-- ===================================================================== --}} @if($showClientCreateModal) @endif {{-- ===================================================================== --}} {{-- MODAL LISTE DES CLIENTS --}} {{-- ===================================================================== --}} @if($showClientsModal) @endif