{% extends 'TopxiaWebBundle:Question:question-base-layout.html.twig' %}

{% block heading %}
  {{ question.stem|fill_question_stem_html|bbCode2Html|raw }}
{% endblock %}

{% block body %}

{% if itemResult.answer|default(null) %}
{% set fileItemResultAnswer = itemResult.answer|split(',') %}
{% endif %}
  <div class="homework-question-fill question-fill-inputs">
    {% for index,answer in question.answer %}
      <input class="form-control " type="text" data-type="fill" name="answer[{{ question.id }}][]" placeholder="填空({{ loop.index }})答案，请填在这里" value="{% if fileItemResultAnswer[index]|default("") %} {{ fileItemResultAnswer[index]|default("") }}  {% endif %}" />
    {% endfor %}
  </div>
{% endblock %}

{% block footer %}

{% endblock %}