@if($document->doc_status == 'draft' && $document->doc_publishing_type == 'scheduled') @if($document->doc_publishing_scheduled_status == 'pending')
@lang('lang.scheduled_publishing_info') : {{ runtimeDate($document->doc_publishing_scheduled_date) }}
@endif @if($document->doc_publishing_scheduled_status == 'failed')
@lang('lang.scheduled_publishing_failed_info') : {{ runtimeDate($document->doc_publishing_scheduled_date) }}
@endif @endif

@lang('lang.service_provider')

{{ config('system.settings_company_name') }}

@if(config('system.settings_company_address_line_1'))
{{ config('system.settings_company_address_line_1') }}
@endif @if(config('system.settings_company_city'))
{{ config('system.settings_company_city') }}
@endif @if(config('system.settings_company_state'))
{{ config('system.settings_company_state') }}
@endif @if(config('system.settings_company_zipcode'))
{{ config('system.settings_company_zipcode') }}
@endif @if(config('system.settings_company_country'))
{{ config('system.settings_company_country') }}
@endif @if(config('system.settings_company_customfield_1') != '')
{{ config('system.settings_company_customfield_1') }}
@endif @if(config('system.settings_company_customfield_2') != '')
{{ config('system.settings_company_customfield_2') }}
@endif @if(config('system.settings_company_customfield_3') != '')
{{ config('system.settings_company_customfield_3') }}
@endif @if(config('system.settings_company_customfield_4') != '')
{{ config('system.settings_company_customfield_4') }}
@endif
@if($document->docresource_type == 'client')

@lang('lang.client')

{{ $document->client_company_name }}

@if($document->client_billing_street)
{{ $document->client_billing_street }}
@endif @if($document->client_billing_city)
{{ $document->client_billing_city }}
@endif @if($document->client_billing_state)
{{ $document->client_billing_state }}
@endif @if($document->client_billing_zip)
{{ $document->client_billing_zip }}
@endif @if($document->client_billing_country)
{{ $document->client_billing_country }}
@endif @foreach($customfields as $field) @if($field->customfields_show_invoice == 'yes' && $field->customfields_status == 'enabled') @php $key = $field->customfields_name; @endphp @php $customfield = $document[$key] ?? ''; @endphp @if($customfield != '')
{{ $field->customfields_title }}: {{ runtimeCustomFieldsFormat($customfield, $field->customfields_datatype) }}
@endif @endif @endforeach
@endif @if($document->docresource_type == 'lead')

@lang('lang.client')

@if($document->lead_company_name)

{{ $document->lead_company_name }}

@else

{{ $document->lead_firstname }} {{ $document->lead_lastname }}

@endif @if($document->lead_street)
{{ $document->lead_street }}
@endif @if($document->lead_city)
{{ $document->lead_city }}
@endif @if($document->lead_state)
{{ $document->lead_state }}
@endif @if($document->lead_zip)
{{ $document->lead_zip }}
@endif @if($document->lead_country)
{{ $document->lead_country }}
@endif
@endif