@php use App\Models\Cuestionario; use App\Support\EscalaSaber; use App\Support\EscalaValorativa; $tipo = $fila['tipo'] ?? ''; @endphp @if(in_array($tipo, ['categoria', 'subcategoria'], true)) @elseif($tipo === 'actividad') @php $nota = $valor['nota'] ?? null; $max = $valor['max'] ?? null; $esSaber = ($valor['tipo_evaluacion'] ?? $fila['tipo_evaluacion'] ?? null) === Cuestionario::TIPO_SABER; @endphp @if($nota === null) — @elseif($esSaber) {{ EscalaSaber::formatearTotal((float) $nota) }} @elseif($max !== null) {{ number_format($nota, 1) }} / {{ number_format($max, 1) }} @else {{ number_format($nota, 1) }} @endif @else @php $notaEscala = $valor['nota_escala'] ?? null; @endphp {{ $notaEscala === null ? '—' : EscalaValorativa::formatear($notaEscala, $colegio ?? null) }} @endif