{{-- Espacio --}} {{-- SECCIÓN INGRESOS --}} @foreach ($ingresos_gestion as $ingreso_nombre => $cuentas) @foreach ($cuentas as $cuenta) @endforeach @endforeach {{-- Espacio --}} {{-- SECCIÓN GASTOS --}} @foreach ($gastos_gestion as $gastos_nombre => $cuentas) @foreach ($cuentas as $cuenta) @endforeach @endforeach @php $resultado_act = $total_ingresos_act - $total_gastos_act; $resultado_ant = $total_ingresos_ant - $total_gastos_ant; @endphp
RED NACIONAL DE HOSPITALES
ESTADO DE RENDIMIENTO ECONÓMICO
DEL: {{ $fecha_desde }} AL {{ $fecha_hasta }}
CONCEPTO (INGRESOS Y GASTOS) CORRIENTE ANTERIOR
INGRESOS DE GESTIÓN
{{ $cuentas->first()->padre_nombre }} {{ $cuentas->sum('saldo_corriente') }} {{ $cuentas->sum('saldo_anterior') }}
   {{ $cuenta->nombre }} {{ $cuenta->saldo_corriente }} {{ $cuenta->saldo_anterior }}
TOTAL INGRESOS DE GESTIÓN {{ $total_ingresos_act }} {{ $total_ingresos_ant }}
GASTOS DE GESTIÓN
{{ $cuentas->first()->padre_nombre }} {{ $cuentas->sum('saldo_corriente') }} {{ $cuentas->sum('saldo_anterior') }}
   {{ $cuenta->nombre }} {{ $cuenta->saldo_corriente }} {{ $cuenta->saldo_anterior }}
SUBTOTAL GASTOS {{ $total_gastos_act }} {{ $total_gastos_ant }}
RESULTADO DEL EJERCICIO (AHORRO/DESAHORRO) {{ $resultado_act }} {{ $resultado_ant }}
TOTAL DE GASTOS DE GESTIÓN {{ $resultado_act + $total_gastos_act }} {{ $resultado_ant + $total_gastos_ant }}