@php $snapshot = $row->snapshot; $labels = ['company'=>'Issuing entity','address'=>'Company address','registration'=>'Registration','vessel'=>'Vessel','imo'=>'IMO number','owner'=>'Registered owner','charterer'=>'Charterer','contract'=>'Charter reference','location'=>'Location','effective_at'=>'Actual effective time and UTC offset','off_hire_reason'=>'Off-hire reason','evidence'=>'Evidence references','remarks'=>'Conditions or reservations','replacement'=>'Replaces']; $fields = collect($labels)->filter(fn ($label, $field) => filled($snapshot[$field] ?? null)); @endphp

{{ $snapshot['declaration'] }}

@if($pdfCompact ?? false) @foreach($fields->except(['company','address'])->chunk(2) as $pair) @foreach($pair as $field=>$label) @endforeach @if($pair->count() === 1)@endif @endforeach
{{ $label }}
{{ $snapshot[$field] }}
@else
@foreach($fields as $field=>$label)
{{ $label }}
{{ $snapshot[$field] }}
@endforeach
@endif @if(!empty($snapshot['rob']))

Remaining on board

@foreach($snapshot['rob'] as $entry)@endforeach
ProductQuantityUnit
{{ $entry['product'] }}{{ $entry['quantity'] }}{{ $entry['unit'] }}
@endif