Configuración del Período
@php $x=0; $total=$totalRetenciones=$totalAnticipos=$ENERO=$FEBRERO=$MARZO=$ABRIL=$MAYO=$JUNIO=$JULIO=$AGOSTO=$SEPTIEMBRE=$OCTUBRE=$NOVIEMBRE=$DICIEMBRE=0; (\App\Models\Person::whereId(session('current_person_id'))->first()->person_type_id ==1)? $porcentaje = 0.20 : $porcentaje =0.30; $impuesto = $resultado[4]['totales'] * $porcentaje; $totalRetenciones = $retencionesGanancias->UNO + $retencionesGanancias->DOS+ $retencionesGanancias->TRES + $retencionesGanancias->CUATRO + $retencionesGanancias->CINCO + $retencionesGanancias->SEIS + $retencionesGanancias->SIETE + $retencionesGanancias->OCHO + $retencionesGanancias->NUEVE + $retencionesGanancias->DIEZ + $retencionesGanancias->ONCE + $retencionesGanancias->DOCE ; $totalAnticipos = $anticiposGanancias->UNO + $anticiposGanancias->DOS+ $anticiposGanancias->TRES + $anticiposGanancias->CUATRO + $anticiposGanancias->CINCO + $anticiposGanancias->SEIS + $anticiposGanancias->SIETE + $anticiposGanancias->OCHO + $anticiposGanancias->NUEVE + $anticiposGanancias->DIEZ + $anticiposGanancias->ONCE + $anticiposGanancias->DOCE; $pagar = $impuesto - $totalAnticipos - $totalRetenciones @endphp