Fiche Client - {{ $client->fullName() }}

Informations client

@if($client->address) @endif @if($client->notes) @endif
Nom : {{ $client->lastname ?? '-' }} Prénom : {{ $client->firstname ?? '-' }}
Email : {{ $client->email ?? '-' }} Téléphone : {{ $client->phones->first()->name ?? $client->phone ?? '-' }}
Adresse : {{ $client->address->line_1 ?? '' }} @if($client->address->line_2) {{ $client->address->line_2 }} @endif @if($client->address->zip_code && $client->address->city) - {{ $client->address->zip_code }} {{ $client->address->city }} @endif
Date de création : {{ $clientCreationDate->format('d/m/Y') }} Statut du dernier dossier : @if($lastStatus) {{ $lastStatus->label() }} @else Aucun dossier @endif
Commentaires : {{ $client->notes }}
@if($dossiersActifs->count() > 0)

Dossiers actifs ({{ $dossiersActifs->count() }})

@foreach($dossiersActifs as $option) @php $lot = $option->product; $program = $lot ? $lot->program : null; $state = $option->state; $fiscalites = $program ? $program->fiscalites->pluck('type')->map(fn($f) => $f->label())->toArray() : []; $fiscaliteLibelle = !empty($fiscalites) ? implode(', ', $fiscalites) : '-'; $typologie = $lot && $lot->type ? $lot->type->label() : '-'; $prixTTC = $lot ? $lot->prices->where('type', 'prix_ttc')->first() : null; $prix = $prixTTC ? number_format($prixTTC->value, 0, ',', ' ') . ' €' : '-'; $dateReservation = null; if ($state === \App\Enums\OptionState::PROMESSE_VENTE_SIGNEE || $state === \App\Enums\OptionState::ACTE_DEFINITIF_SIGNE) { $dateReservation = $option->updated_at; } @endphp @if($program) @endif @endforeach
Programme Lot Fiscalité Typologie Statut Date pose Date réservation Prix
{{ $program->name }} Lot n°{{ $lot->number ?? '-' }} {{ $fiscaliteLibelle }} {{ $typologie }} {{ $state->label() }} {{ $option->created_at->format('d/m/Y') }} {{ $dateReservation ? $dateReservation->format('d/m/Y') : '-' }} {{ $prix }}
@endif @if($historiqueVentes->count() > 0)

Historique des ventes ({{ $historiqueVentes->count() }})

@foreach($historiqueVentes as $option) @php $lot = $option->product; $program = $lot ? $lot->program : null; $state = $option->state; $prixTTC = $lot ? $lot->prices->where('type', 'prix_ttc')->first() : null; $prix = $prixTTC ? number_format($prixTTC->value, 0, ',', ' ') . ' €' : '-'; $dateArchivage = $option->updated_at; @endphp @if($program) @endif @endforeach
Date d'archivage Programme Lot Statut Prix
{{ $dateArchivage->format('d/m/Y') }} {{ $program->name }} Lot n°{{ $lot->number ?? '-' }} {{ $state->label() }} {{ $prix }}
@endif