@php $establishment = $document->establishment; $document_number = $document->series.'-'.str_pad($document->number, 8, '0', STR_PAD_LEFT); @endphp @if($company->logo) @else @endif
logo}"))}};base64, {{base64_encode(file_get_contents(public_path("storage/uploads/logos/{$company->logo}")))}}" alt="{{ $company->name }}" class="company_logo" style="max-width: 300px"> {{----}}

{{ $company->name }}

{{ 'RUC '.$company->number }}

{{ ($establishment->address !== '-')? $establishment->address : '' }} {{ ($establishment->district_id !== '-')? ', '.$establishment->district->description : '' }} {{ ($establishment->province_id !== '-')? ', '.$establishment->province->description : '' }} {{ ($establishment->department_id !== '-')? '- '.$establishment->department->description : '' }}
{{ ($establishment->email !== '-')? $establishment->email : '' }}
{{ ($establishment->telephone !== '-')? $establishment->telephone : '' }}

{{ $document->document_type->description }}

{{ $document_number }}

Fecha Emisión: {{ $document->date_of_issue->format('Y-m-d') }}
Fecha Inicio de Traslado: {{ $document->date_of_shipping->format('Y-m-d') }}
Peso Bruto Total({{ $document->unit_type_id }}): {{ $document->total_weight }}
Punto de Partida: {{ $document->sender_address_data['location_id'] }} - {{ $document->sender_address_data['address'] }}
Punto de Llegada: {{ $document->receiver_address_data['location_id'] }} - {{ $document->receiver_address_data['address'] }}
Datos del Remitente: {{ $document->sender_data['name'] }} - {{ $document->sender_data['identity_document_type_description'] }} {{ $document->sender_data['number'] }}
Datos del Destinatario: {{ $document->receiver_data['name'] }} - {{ $document->receiver_data['identity_document_type_description'] }} {{ $document->receiver_data['number'] }}
@if($document->transport_data) @endif @if($document->driver->number) @endif @if($document->driver->license) @endif
TRANSPORTE
Número de placa del vehículo: {{ $document->transport_data['plate_number'] }}
Conductor: {{ $document->driver->number }}
Licencia del conductor: {{ $document->driver->license }}
@foreach($document->items as $row) @endforeach
Item Código Descripción Modelo Unidad Cantidad
{{ $loop->iteration }} {{ $row->item->internal_id }} @if($row->name_product_pdf) {!!$row->name_product_pdf!!} @else {!!$row->item->description!!} @endif @if (!empty($row->item->presentation)) {!!$row->item->presentation->description!!} @endif @if($row->attributes) @foreach($row->attributes as $attr)
{!! $attr->description !!} : {{ $attr->value }} @endforeach @endif @if($row->discounts) @foreach($row->discounts as $dtos)
{{ $dtos->factor * 100 }}% {{$dtos->description }} @endforeach @endif @if($row->relation_item->is_set == 1)
@inject('itemSet', 'App\Services\ItemSetService') @foreach ($itemSet->getItemsSet($row->item_id) as $item) {{$item}}
@endforeach @endif @if($document->has_prepayment)
*** Pago Anticipado *** @endif
{{ $row->item->model ?? '' }} {{ $row->item->unit_type_id }} @if(((int)$row->quantity != $row->quantity)) {{ $row->quantity }} @else {{ number_format($row->quantity, 0) }} @endif
@if($document->observations)
OBSERVACIONES
{{ $document->observations }}
@endif @if($document->qr)
@endif