@php $seller = $fiscalParties['seller']; $buyer = $fiscalParties['buyer']; $buyerTitle = $buyer['legal_name'] ?: $buyer['name']; $sellerAddress = implode("\n", array_filter([ $seller['address'] ?? null, $seller['address2'] ?? null, trim(($seller['zipcode'] ?? '').' '.($seller['city'] ?? '')) ?: null, ])); @endphp

{{ $seller['legal_name'] ?: setting('app.name') }}

@if ($sellerAddress !== '')
{{ $sellerAddress }}
@endif @if (!empty($seller['siren'])) {{ __('einvoicing.profile.siren') }} : {{ $seller['siren'] }}
@endif @if (!empty($seller['siret'])) {{ __('einvoicing.profile.siret') }} : {{ $seller['siret'] }}
@endif @if (!empty($seller['vat_number'])) {{ __('einvoicing.profile.vat_number') }} : {{ $seller['vat_number'] }} @endif

{{ __('client.invoices.billto', ['name' => $buyerTitle]) }}

@if ($buyer['legal_name'] && $buyer['name']) {{ $buyer['name'] }}
@endif @if (!empty($buyer['email'])) {{ $buyer['email'] }}
@endif {{ $buyer['address'] }}@if (!empty($buyer['address2'])) {{ $buyer['address2'] }}@endif
@if (!empty($buyer['region'])){{ $buyer['region'] }} ยท @endif{{ $buyer['zipcode'] }} {{ $buyer['city'] }}
{{ \App\Helpers\Countries::names()[$buyer['country']] ?? $buyer['country'] }}
@foreach ([ 'siren' => __('einvoicing.profile.siren'), 'siret' => __('einvoicing.profile.siret'), 'rna_number' => __('einvoicing.profile.rna_number'), 'vat_number' => __('einvoicing.profile.vat_number'), 'tax_registration_number' => __('einvoicing.profile.tax_registration_number'), ] as $field => $label) @if (!empty($buyer[$field])) {{ $label }} : {{ $buyer[$field] }}
@endif @endforeach @if (!empty($buyer['additional_details']))
{!! nl2br(e($buyer['additional_details'])) !!} @endif