This commit is contained in:
Ross
2021-09-12 09:36:14 +01:00
parent 83bc9d89ec
commit 03bcd07862
+57 -49
View File
@@ -1,45 +1,53 @@
{% extends 'longs/exams.html' %} {% extends 'longs/exams.html' %}
{% block content %} {% block content %}
<a href="{% url 'longs:exam_question_detail' exam.id question_details.current %}" title="View the Question">View</a> <a href="{% url 'longs:exam_question_detail' exam.id question_details.current %}" title="View the Question">View</a>
<a href="{% url 'longs:long_update' question.id %}" title="Edit the Question">Edit</a> <a href="{% url 'longs:long_update' question.id %}" title="Edit the Question">Edit</a>
{% if request.user.is_superuser %} {% if request.user.is_superuser %}
<a href="{% url 'admin:longs_long_change' question.id %}" title="Edit the Question using the admin interface">Admin <a href="{% url 'admin:longs_long_change' question.id %}" title="Edit the Question using the admin interface">Admin
Edit</a> <a href="{% url 'admin:longs_ciduseranswer_change' answer.id %}" Edit</a> <a href="{% url 'admin:longs_ciduseranswer_change' answer.id %}"
title="Edit the user answer using the admin interface">Admin title="Edit the user answer using the admin interface">Admin
Edit (user answer)</a> Edit (user answer)</a>
{% endif %} {% endif %}
<h2>Marking question <a href="{% url 'longs:mark_question_overview' exam.id question_details.current|add:'-1' %}" <h2>Marking question <a href="{% url 'longs:mark_question_overview' exam.id question_details.current|add:'-1' %}"
title="View question answers">{{question_details.current}}</a> of {{question_details.total}}</h2> title="View question answers">{{question_details.current}}</a> of {{question_details.total}}</h2>
{% if discrepancy_form %} {% if discrepancy_form %}
<div class="alert alert-info sticky-alert" role="alert"> <div class="alert alert-info sticky-alert" role="alert">
<h3>This answer has discrepant scores</h3> <h3>This answer has discrepant scores</h3>
Either edit your score before or set the overall score here.<br/> Either edit your score before or set the overall score here.<br/>
<form method="POST" class="post-form">{% csrf_token %} <form method="POST" class="post-form">{% csrf_token %}
<input type="hidden" name="form_id" value="discrepancy_form"> <input type="hidden" name="form_id" value="discrepancy_form">
{{ discrepancy_form.as_p }} {{ discrepancy_form.as_p }}
<button type="submit" name="save" class="save btn btn-default" title="Save score">Save Score</button> <button type="submit" name="save" class="save btn btn-default" title="Save score">Save Score</button>
</form> </form>
</div> <h4>Marker scores and reason</h4>
<ul>
{% for mark_objects in answer.mark %}{% endfor %}
<li>{{answer.marker}}: answer.score<br/>
{{answer.mark_reason}}
</li>
{% endfor %}
</ul>
</div>
{% endif %} {% endif %}
{% if not next_unmarked_id and not unmarked %} {% if not next_unmarked_id and not unmarked %}
<div class="alert alert-info sticky-alert" role="alert">Success! Marking question complete. <br />Return to <a <div class="alert alert-info sticky-alert" role="alert">Success! Marking question complete. <br />Return to <a
href="{% url 'longs:mark_question_overview' exam.id question_details.current|add:'-1' %}">question href="{% url 'longs:mark_question_overview' exam.id question_details.current|add:'-1' %}">question
overview</a>, <a href="{% url 'longs:mark_overview' pk=exam.pk %}">marking overview</a>, <a href="{% url 'longs:mark_overview' pk=exam.pk %}">marking
overview</a><br /> overview</a><br />
{% if previous_cid %} {% if previous_cid %}
<a href="{% url 'longs:mark_answer' exam_id=exam.pk question_number=question_details.current|add:'-1' cid=previous_cid %}">Previous <a href="{% url 'longs:mark_answer' exam_id=exam.pk question_number=question_details.current|add:'-1' cid=previous_cid %}">Previous
candidate</a> candidate</a>
{% endif %} {% endif %}
{% if next_cid %} {% if next_cid %}
<a href="{% url 'longs:mark_answer' exam_id=exam.pk question_number=question_details.current|add:'-1' cid=next_cid %}">Next <a href="{% url 'longs:mark_answer' exam_id=exam.pk question_number=question_details.current|add:'-1' cid=next_cid %}">Next
candidate</a> candidate</a>
{% endif %} {% endif %}
</div> </div>
{% endif %} {% endif %}
<span>Marking CID: {{answer.cid}} ({{unmarked|length}} answer(s) left to mark)</span> <span>Marking CID: {{answer.cid}} ({{unmarked|length}} answer(s) left to mark)</span>
@@ -51,17 +59,17 @@ Either edit your score before or set the overall score here.<br/>
<div class="pre-whitespace multi-image-block"><b>Series:</b> <div class="pre-whitespace multi-image-block"><b>Series:</b>
{% for series in question.series.all %} {% for series in question.series.all %}
<span class="series-block"> <span class="series-block">
<span> <span>
Series {{ forloop.counter }}: Series {{ forloop.counter }}:
<a href="{% url 'longs:long_series_detail' pk=series.pk %}"> <a href="{% url 'longs:long_series_detail' pk=series.pk %}">
{{series.get_block}} {{series.get_block}}
</a> </a>
<a href="#" <a href="#"
onclick="return window.create_popup_window('/longs/series/{{series.pk}}', 'Series')">Popup</a> onclick="return window.create_popup_window('/longs/series/{{series.pk}}', 'Series')">Popup</a>
</span>
</span> </span>
</span>
{% endfor %} {% endfor %}
</div> </div>
</details> </details>
@@ -103,22 +111,22 @@ Either edit your score before or set the overall score here.<br/>
{{ form.as_p }} {{ form.as_p }}
<button type="submit" name="save" class="save btn btn-default" title="Save answer">Save</button> <button type="submit" name="save" class="save btn btn-default" title="Save answer">Save</button>
{% if next_unmarked_id %} {% if next_unmarked_id %}
<button type="submit" name="next" class="save btn btn-default" <button type="submit" name="next" class="save btn btn-default"
title="Save answer and move to next question">Next answer</button> title="Save answer and move to next question">Next answer</button>
<!-- <button type="submit" name="skip" class="save btn btn-default">Skip</button> --> <!-- <button type="submit" name="skip" class="save btn btn-default">Skip</button> -->
{% else %} {% else %}
{% if not unmarked %} {% if not unmarked %}
Success! Marking question complete. <a href="{% url 'longs:mark_overview' pk=exam.pk %}">Return to marking Success! Marking question complete. <a href="{% url 'longs:mark_overview' pk=exam.pk %}">Return to marking
overview</a> overview</a>
{% endif %} {% endif %}
{% endif %} {% endif %}
</form> </form>
</div> </div>
{% if previous_cid %} {% if previous_cid %}
<a href="{% url 'longs:mark_answer' exam_id=exam.pk question_number=question_details.current|add:'-1' cid=previous_cid %}">Previous <a href="{% url 'longs:mark_answer' exam_id=exam.pk question_number=question_details.current|add:'-1' cid=previous_cid %}">Previous
candidate</a> candidate</a>
{% endif %} {% endif %}
{% if next_cid %} {% if next_cid %}
<a href="{% url 'longs:mark_answer' exam_id=exam.pk question_number=question_details.current|add:'-1' cid=next_cid %}">Next candidate</a> <a href="{% url 'longs:mark_answer' exam_id=exam.pk question_number=question_details.current|add:'-1' cid=next_cid %}">Next candidate</a>
{% endif %} {% endif %}
{% endblock %} {% endblock %}