@php $titre = $panneau->nom ?? null; $logo = $panneau->logo ?? null; @endphp @php $intervenants = $panneau->intervenants ->where('numeroOrdre', 1) ->filter(function($i) { return Str::contains(strtolower($i->type), 'ouvrage'); }); @endphp
@foreach($intervenants as $intervenant) @php $entete = $intervenant->logoEntete ?? 'les_deux'; $showLogo1Entete = in_array($entete, ['gauche', 'les_deux']); $showLogo2Entete = in_array($entete, ['droite', 'les_deux']); @endphp @if($intervenant->logo && $showLogo1Entete)
Logo {{ $intervenant->libelle }}
@endif @if($intervenant->logo2 && $showLogo2Entete)
Logo2 {{ $intervenant->libelle }}
@endif @endforeach
@if($titre || $logo ) @if($logo)
Titre
@else

{{ $titre }}

@endif @endif

{{ $panneau->adresse }}
{{ $panneau->codePostal }} {{ $panneau->ville }}
France

@if($panneau->sousTitre)

{{ $panneau->sousTitre }}

@endif
@foreach($panneau->labels->where('actif', true) as $label)
Logo {{ $label->libelle }}
@endforeach