@extends('admin.layout') @section('title', 'Fiche client') @section('content')

{{ $client['RAISON_SOCIALE'] ?: $client['NOMFAMILLE'] . ' ' . $client['PRENOM'] }}

@include('admin.gestan._stale_banner')
{{-- ========================= --}} {{-- INFOS CLIENT --}} {{-- ========================= --}}

Informations générales

ID CLIENT {{ $client['IDCONTACT'] }}
Raison Sociale {{ $client['RAISON_SOCIALE'] }}
Nom du client {{ $client['NOMFAMILLE'] }} {{ $client['PRENOM'] }}
Adresse {{ $client['ADRESSEP1'] }}
@if ($client['ADRESSEP2']) {{ $client['ADRESSEP2'] }}
@endif {{ $client['CPOSTALP'] }} {{ $client['VILLEP'] }}
Numéro de téléphone {{ $client['TELP1'] }}
Email {{ $client['EMAILP'] }}
Créateur {{ $client['USCRE'] }} {{ $client['DHCRE'] }}
{{-- ========================= --}} {{-- HISTORIQUE DEVIS --}} {{-- ========================= --}}

Historique des derniers devis ({{ count($devis ?? []) }})


@if (!empty($devis))
@foreach ($devis as $d) @php $itemId = 'devis_' . $d['IDFACTURE']; $isOpen = $loop->first; @endphp

Nature {{ $d['NATURE'] }}
Référence {{ $d['VREF'] ?: '—' }}
Montant {{ $d['MTT_TOTAL_TTC'] }} € TTC
Responsable {{ $d['US_RESP'] }}
Date création {{ $d['DHCRE'] }}
@endforeach

@if ($devisTotal > 20) Voir tous les devis ({{ $devisTotal }}) @endif @else

Aucun devis trouvé.

@endif
{{-- ========================= --}} {{-- HISTORIQUE FACTURES --}} {{-- ========================= --}}

Historique des dernières factures ({{ count($factures ?? []) }})

@if (!empty($factures))
@foreach ($factures as $f) @php $itemId = 'facture_' . $f['IDFACTURE']; $isOpen = $loop->first; @endphp

Nature {{ $f['NATURE'] }}
Référence {{ $f['VREF'] ?: '—' }}
Montant {{ $f['MTT_TOTAL_TTC'] }} € TTC
Responsable {{ $f['US_RESP'] }}
Date création {{ $f['DHCRE'] }}
@endforeach

@if ($facturesTotal > 20) Voir toutes les factures ({{ $facturesTotal }}) @endif @else

Aucune facture trouvée.

@endif
{{-- ========================= --}} {{-- HISTORIQUE COMMANDES --}} {{-- ========================= --}}

Historique des dernières commandes ({{ count($commandes ?? []) }})


@if (!empty($commandes))
@foreach ($commandes as $c) @php $itemId = 'commande_' . $c['id_process']; $isOpen = $loop->first; @endphp

Type {{ $c['type'] ?? '—' }}
Modèle {{ $c['modele'] ?? '—' }}
Couleur {{ $c['couleur'] ?? '—' }}
Finition {{ $c['finition'] ?? '—' }}
Date fabrication {{ $c['date_fabrication'] ?? '—' }}
Date réception entrepôt {{ $c['date_reception_entrepot'] ?? '—' }}
État {{ $c['etat'] ?? '—' }}
@if (!empty($c['lien_pdf'])) @endif
@endforeach

@if ($commandesTotal > 20) Voir toutes les commandes ({{ $commandesTotal }}) @endif @else

Aucune commande trouvée.

@endif
{{-- ========================= --}} {{-- HISTORIQUE CHANTIERS --}} {{-- ========================= --}}

Historique des derniers chantiers ({{ count($chantiers ?? []) }})


@if (!empty($chantiers))
@foreach ($chantiers as $ch) @php $itemId = 'chantier_' . $ch['id_rdv']; $isOpen = $loop->first; @endphp

Date début {{ $ch['date_debut'] }}
Date fin {{ $ch['date_fin'] }}
Employés @if (!empty($ch['employes_details']))
    @foreach ($ch['employes_details'] as $u)
  • {{ $u['prenom'] }} {{ $u['nom'] }}
  • @endforeach
@else — @endif
Devis liés
@endforeach

@if ($chantiersTotal > 20) Voir tous les chantiers ({{ $chantiersTotal }}) @endif @else

Aucun chantier trouvé.

@endif
{{-- ========================= --}} {{-- HISTORIQUE INTERVENTIONS --}} {{-- ========================= --}}

Historique des dernières interventions ({{ count($interventions ?? []) }})


@if (!empty($interventions))
@foreach ($interventions as $i) @php $itemId = 'inter_' . $i['IDINTERVENTION']; $isOpen = $loop->first; @endphp

Libellé {{ $i['LIBINTER'] }}
Créée par {{ $i['USCRE'] }}
Date {{ $i['DHCRE'] }}
@endforeach

@if ($interventionsTotal > 20) Voir toutes les interventions ({{ $interventionsTotal }}) @endif @else

Aucune intervention enregistrée.

@endif
{{-- ========================= --}} {{-- RETOUR --}} {{-- ========================= --}}
Retour à la liste
@endsection