Reporte Compras


Empresa:

{{$company->name}}

Fecha:

{{date('Y-m-d')}}

N° Documento:

{{$company->number}}

Establecimiento:

{{$establishment->address}} - {{$establishment->address}} - {{$establishment->country->name}} - {{$establishment->department->name}} - {{$establishment->city->name}}

@if(!empty($records))
@php $sum_total = 0; @endphp @foreach($records as $key => $value) @php $value->total_taxed = (in_array($value->document_type_id,['01','03']) && in_array($value->state_type_id,['09','11'])) ? 0 : $value->total_taxed; $value->total_igv = (in_array($value->document_type_id,['01','03']) && in_array($value->state_type_id,['09','11'])) ? 0 : $value->total_igv; $value->total = (in_array($value->document_type_id,['01','03']) && in_array($value->state_type_id,['09','11'])) ? 0 : $value->total; $state = $value->state_type_id; $sum_total += $value->total; @endphp @endforeach
# Tipo Doc Número F. Emisión F. Vencimiento Cliente N° Documento F. Pago Estado Moneda T. Impuestos Total
{{$loop->iteration}} {{$value->document_type->id}} {{$value->series}}-{{$value->number}} {{$value->date_of_issue->format('Y-m-d')}} {{$value->date_of_due->format('Y-m-d')}} {{$value->supplier->name}} {{$value->supplier->number}} {{isset($value->purchase_payments['payment_method_type']['description'])?$value->purchase_payments['payment_method_type']['description']:'-'}} {{$value->state_type->description}} {{$value->currency_type_id}} {{$value->total_tax}} {{$value->state_type_id == '11' ? 0 : $value->total + $value->total_perception}}
Total: {{ number_format($sum_total, 2, ".", "") }}
@else

No se encontraron registros.

@endif