Running the old version.
[edumed.git] / wtem / templates / wtem / exercises / edumed_wybor.html
1 <div class="exercise exercise-wtem wybor" data-type="wybor" data-id="{{exercise.id}}">
2
3     {% include "wtem/exercises/exercise_no.html" %}
4     {% autoescape off %}
5     <div class="description">
6         {% for para in exercise.description %}
7             <p class="paragraph">
8                 {{para}}
9             </p>
10         {% endfor %}
11         {% if exercise.points %}
12             <span class="instruction">
13                 {% if exercise.answer|length == 1 %}
14                     Tylko jedna odpowiedź jest prawidłowa.
15                 {% else %}
16                     Zaznacz wszystkie prawidłowe odpowiedzi.
17                 {% endif %}
18             </span>
19         {% endif %}
20     </div>
21     {% endautoescape %}
22     <div class="question" data-no="1">
23         <ol class="lista num">
24             {% for option in exercise.options %}
25                 <li class="question-piece" data-name="{{option.id}}">
26                     <input type="{% if exercise.answer|length == 1 %}radio{% else %}checkbox{% endif %}" name="{% if exercise.answer|length == 1 %}e{{no}}{% else %}e{{no}}_{{option.id}}{% endif %}" id="e{{no}}_{{option.id}}"{% if option.id|stringformat:"s" in exercise.saved_answer.closed_part %} checked="checked"{% endif %}>
27                     <label for="e{{no}}_{{option.id}}">{{option.text}}</label>
28                 </li>
29             {% endfor %}
30         </ol>
31     </div>
32
33     {% if exercise.open_part %}
34     <div class="open_part">
35         <div class="description">
36             {% for para in exercise.open_part %}
37                 <p class="paragraph">
38                     {{para}}
39                 </p>
40             {% endfor %}
41         </div>
42         <textarea style="width: 100%; margin-top:10px;" rows="{{exercise.open_part_rows|default:10}}">{{ exercise.saved_answer.open_part }}</textarea>
43     </div>
44     {% endif %}
45
46 </div>