{{-- ENCABEZADO --}}

Resultados

Detalle de evaluación

Consulta el resultado y las respuestas registradas.

Volver a resultados
{{-- INFORMACIÓN PRINCIPAL --}}
{{-- PARTICIPANTE --}}

Participante

{{ $result->attempt?->folio?->participant_name ?: 'Sin nombre' }}

@if($result->attempt?->folio?->participant_email)

{{ $result->attempt->folio->participant_email }}

@endif
{{-- FOLIO --}}

Folio

{{ $result->attempt?->folio?->folio }}

{{-- RESULTADO --}}

Resultado

{{ number_format($result->percentage, 2) }}%

{{ number_format($result->score, 2) }} / {{ number_format($result->max_score, 2) }} puntos

{{-- ESTADO --}}

Estado

@if($result->is_approved === true) Aprobado @elseif($result->is_approved === false) No aprobado @else Sin regla @endif
{{-- DATOS DE EVALUACIÓN --}}

Información de la evaluación

Institución

{{ $result->institution?->name }}

Cuestionario

{{ $result->questionnaire?->title }}

Inicio

{{ $result->attempt?->started_at?->format('d/m/Y H:i:s') ?? '—' }}

Finalización

{{ $result->attempt?->completed_at?->format('d/m/Y H:i:s') ?? '—' }}

Duración

@if($result->attempt?->duration_seconds !== null) {{ gmdate( 'H:i:s', $result->attempt->duration_seconds ) }} @else — @endif

Fecha de evaluación

{{ $result->evaluated_at?->format('d/m/Y H:i:s') ?? '—' }}

{{-- INTERPRETACIÓN --}}

Interpretación

@if($result->level || $result->interpretation) @if($result->level)

{{ $result->level }}

@endif @if($result->interpretation)

{{ $result->interpretation }}

@endif @else

Este cuestionario todavía no tiene una regla de interpretación configurada para este porcentaje.

@endif
{{-- Respuestas --}}
{{-- Encabezado --}}

Respuestas del participante

Revisión detallada de las preguntas asignadas al intento.

@foreach($result->attempt?->attemptQuestions ?? [] as $attemptQuestion) @php $question = $attemptQuestion->question; $answers = $result->attempt->answers ->where('question_id', $question->id); $correctOptions = $question->options ->where('is_active', true) ->where('is_correct', true); $earnedPoints = (float) $answers->sum('points_earned'); $hasCorrectAnswer = $answers ->contains(fn ($answer) => $answer->is_correct === true); $hasIncorrectAnswer = $answers ->contains(fn ($answer) => $answer->is_correct === false); @endphp
{{-- Pregunta --}}
{{ $loop->iteration }}

{{ $question->question_text }}

{{ match($question->type) { 'single' => 'Opción única', 'multiple' => 'Opción múltiple', 'true_false' => 'Verdadero / Falso', 'text' => 'Respuesta abierta', 'scale' => 'Escala', default => 'Pregunta', } }}

Puntuación

{{ number_format($earnedPoints, 2) }} / {{ number_format($question->points, 2) }}

{{-- Grid de respuestas --}}
{{-- RESPUESTA DEL PARTICIPANTE --}}

Respuesta del participante

@if($answers->count())
@foreach($answers as $answer)
@if($answer->is_correct === true)
✓
@elseif($answer->is_correct === false)
×
@else
@endif
@if($answer->option)

{{ $answer->option->option_text }}

@else

{{ $answer->answer_text ?: 'Sin respuesta' }}

@endif
@endforeach
@else

No se registró respuesta.

@endif
{{-- RESPUESTA CORRECTA O REVISIÓN MANUAL --}} @if($question->type === 'text') @php $openAnswer = $answers->first(); @endphp {{-- REVISIÓN MANUAL --}}

Revisión manual

Asigna la puntuación correspondiente a esta respuesta abierta.

Máximo: {{ number_format($question->points, 2) }} pts
@if($openAnswer)
@csrf @method('PUT')

Selecciona la calificación de la respuesta:

{{-- CORRECTA --}} {{-- INCORRECTA --}}
{{-- RESULTADO DE LA REVISIÓN --}} @if($openAnswer->reviewed_at)

Revisión registrada

@if($openAnswer->is_correct === true) Esta respuesta fue marcada como correcta y obtuvo {{ number_format($question->points, 2) }} puntos. @elseif($openAnswer->is_correct === false) Esta respuesta fue marcada como incorrecta y obtuvo 0 puntos. @endif

@endif
@else

No se registró respuesta para esta pregunta.

@endif
@else {{-- RESPUESTA CORRECTA --}}

Respuesta correcta

@if(in_array($question->type, ['single', 'multiple']))
@forelse($correctOptions as $correctOption)
✓

{{ $correctOption->option_text }}

@empty

No hay respuesta correcta configurada.

@endforelse
@else

Esta pregunta no tiene calificación automática.

@endif
@endif
{{-- RESULTADO DE LA PREGUNTA --}}
Resultado de la pregunta @if($hasCorrectAnswer && ! $hasIncorrectAnswer) Correcta @elseif($hasIncorrectAnswer) Incorrecta @else Revisión manual @endif
@endforeach