{% set current_theme = current_theme() %} {% from "macros/form_errors.j2" import render_field_errors, render_form_errors %} {% set config = config() %} {{ current_theme.headertags() }} {{ _('Editar Evaluación') }} {{ current_theme.local_style() }} {{ current_theme.navbar() }}
{{ current_theme.notify() }}

{{ evaluacion.title }}

{{ evaluacion.section.nombre }}

{% if evaluacion.is_exam %} {{ _('Examen') }} {% else %} {{ _('Quiz') }} {% endif %}
{{ _('Configuración de la Evaluación') }}
{{ form.hidden_tag() }}
{{ form.title.label(class="form-label") }} {{ form.title(class="form-control") }} {{ render_field_errors(form.title) }}
{{ form.description.label(class="form-label") }} {{ form.description(class="form-control", rows="3") }} {{ render_field_errors(form.description) }}
{{ form.is_exam(class="form-check-input") }} {{ render_field_errors(form.is_exam) }} {{ form.is_exam.label(class="form-check-label") }}
{{ form.passing_score.label(class="form-label") }}
{{ form.passing_score(class="form-control") }} {{ render_field_errors(form.passing_score) }} %
{{ form.max_attempts.label(class="form-label") }} {{ form.max_attempts(class="form-control") }} {{ render_field_errors(form.max_attempts) }}
{{ _('Deje vacío para intentos ilimitados.') }}
{{ _('Preguntas') }} ({{ preguntas|length }})
{{ _('Nueva Pregunta') }}
{% if preguntas %}
{% for pregunta in preguntas %}
{{ _('Pregunta') }} {{ pregunta.order }}

{{ pregunta.text[:100] }}{% if pregunta.text|length > 100 %}...{% endif %}

{{ _('Tipo') }}: {% if pregunta.type == "boolean" %} {{ _('Verdadero/Falso') }} {% else %} {{ _('Opción Múltiple') }} {% endif %} | {{ pregunta.options|length }} {{ _('opciones') }} {% if pregunta.options %}
{{ _('Opciones') }}:
    {% for option in pregunta.options %}
  • {{ option.text[:50] }}{% if option.text|length > 50 %}...{% endif %}
    {% if pregunta.options|length > 2 %}
    {% endif %}
  • {% endfor %}
{% if pregunta.type != "boolean" or pregunta.options|length < 2 %} {{ _('Agregar opción') }} {% endif %}
{% endif %}
{% endfor %}
{% else %}
No hay preguntas creadas para esta evaluación.
{{ _('Crear primera pregunta') }}
{% endif %}
{% if preguntas %}
{{ _('Evaluación lista para estudiantes') }}:
  • {{ preguntas|length }} {{ _('pregunta(s) configurada(s)') }}
  • {{ _('Puntuación mínima') }}: {{ evaluacion.passing_score }}%
  • {{ _('Máximo intentos') }}: {% if evaluacion.max_attempts %}{{ evaluacion.max_attempts }}{% else %}{{ _('Ilimitado') }}{% endif %}
{% endif %}