Reporte A. Fijos - Compras


@inject('reportService', 'Modules\Report\Services\ReportService') @if($filters['seller_id']) @endif @if($filters['person_id']) @endif

Empresa:

{{$company->name}}

Fecha:

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

Ruc:

{{$company->number}}

Establecimiento:

{{$establishment->address}} - {{$establishment->department->description}} - {{$establishment->district->description}}

Usuario:

{{$reportService->getUserName($filters['seller_id'])}}

Proveedor:

{{$reportService->getPersonName($filters['person_id'])}}

@if(!empty($records))
@php $acum_total_taxed=0; $acum_total_igv=0; $acum_total=0; $acum_total_taxed_usd=0; $acum_total_igv_usd=0; $acum_total_usd=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; @endphp @php if($value->currency_type_id == 'PEN'){ if($state == '11'){ $acum_total += 0; $acum_total_taxed += 0; $acum_total_igv += 0; }else{ $acum_total += $value->total; $acum_total_taxed += $value->total_taxed; $acum_total_igv += $value->total_igv; } }else if($value->currency_type_id == 'USD'){ if($state == '11'){ $acum_total_usd += 0; $acum_total_taxed_usd += 0; $acum_total_igv_usd += 0; }else{ $acum_total_usd += $value->total; $acum_total_taxed_usd += $value->total_taxed; $acum_total_igv_usd += $value->total_igv; } } @endphp @endforeach
# Tipo Doc Número F. Emisión F. Vencimiento Cliente RUCF. PagoEstado Moneda Percepción T.Exonerado T.Inafecta T.Gratuito Total Gravado Total IGV 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->state_type_id == '11' ? 0 : $value->total_perception}} {{$value->state_type_id == '11' ? 0 : $value->total_exonerated}} {{ $value->state_type_id == '11' ? 0 : $value->total_unaffected}} {{ $value->state_type_id == '11' ? 0 : $value->total_free}} {{$value->state_type_id == '11' ? 0 : $value->total_taxed}} {{$value->state_type_id == '11' ? 0 : $value->total_igv}} {{$value->state_type_id == '11' ? 0 : $value->total + $value->total_perception}}
Totales PEN {{$acum_total_taxed}} {{$acum_total_igv}} {{$acum_total}}
Totales USD {{$acum_total_taxed_usd}} {{$acum_total_igv_usd}} {{$acum_total_usd}}
@else

No se encontraron registros.

@endif