.
This commit is contained in:
@@ -64,17 +64,19 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
<form method="POST" class="post-form">{% csrf_token %}
|
<form method="POST" class="post-form">{% csrf_token %}
|
||||||
<div class="form-contents">
|
{% if collection.collection_type == "REP" %}
|
||||||
<fieldset {% if collection.publish_results %}disabled="disabled"{% endif %}>
|
<div class="form-contents">
|
||||||
{{form}}
|
<fieldset {% if collection.publish_results %}disabled="disabled"{% endif %}>
|
||||||
</fieldset>
|
{{form}}
|
||||||
</div>
|
</fieldset>
|
||||||
<p>
|
</div>
|
||||||
{% if collection.publish_results %}
|
<p>
|
||||||
<h4>Answer score: {{answer.score}}</h4>
|
{% if collection.publish_results %}
|
||||||
Answer feedback: {{answer.feedback|safe}}
|
<h4>Answer score: {{answer.score}}</h4>
|
||||||
{% endif %}
|
Answer feedback: {{answer.feedback|safe}}
|
||||||
</p>
|
{% endif %}
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
{% if previous > -1 %}
|
{% if previous > -1 %}
|
||||||
<button type="submit" name="previous" class="save btn btn-default">Previous</button>
|
<button type="submit" name="previous" class="save btn btn-default">Previous</button>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|||||||
@@ -0,0 +1,12 @@
|
|||||||
|
{% extends 'atlas/base.html' %}
|
||||||
|
|
||||||
|
{% block content %}
|
||||||
|
<h2>Collection: {{exam.name}}</h2>
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
{% for case in collection.cases.all %}
|
||||||
|
<li><a href="{% url 'atlas:collection_case_view_review' pk=collection.id case_number=forloop.counter0 %}">Case {{forloop.counter}}</a></li>
|
||||||
|
{% endfor %}
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
{% endblock %}
|
||||||
@@ -2,9 +2,6 @@
|
|||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<h2>{{collection.name}}
|
<h2>{{collection.name}}
|
||||||
<ul>
|
|
||||||
</ul>
|
|
||||||
{% if collection.collection_type == "REP" %}
|
|
||||||
<h2>Start: {{exam.name}}</h2>
|
<h2>Start: {{exam.name}}</h2>
|
||||||
|
|
||||||
Enter your CID and passcode in the below boxes.<br />
|
Enter your CID and passcode in the below boxes.<br />
|
||||||
@@ -48,6 +45,5 @@
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|||||||
@@ -29,6 +29,7 @@ urlpatterns = [
|
|||||||
path("collection/<int:pk>/take/<int:cid>/<str:passcode>", views.collection_take_overview, name="collection_take_overview"),
|
path("collection/<int:pk>/take/<int:cid>/<str:passcode>", views.collection_take_overview, name="collection_take_overview"),
|
||||||
path("collection/<int:pk>/<int:case_number>", views.collection_case_view, name="collection_case_view"),
|
path("collection/<int:pk>/<int:case_number>", views.collection_case_view, name="collection_case_view"),
|
||||||
path("collection/<int:pk>/<int:case_number>/take/<int:cid>/<str:passcode>", views.collection_case_view_take, name="collection_case_view_take"),
|
path("collection/<int:pk>/<int:case_number>/take/<int:cid>/<str:passcode>", views.collection_case_view_take, name="collection_case_view_take"),
|
||||||
|
path("collection/<int:pk>/<int:case_number>/review", views.collection_case_view_review, name="collection_case_view_review"),
|
||||||
path(
|
path(
|
||||||
"collection/<int:pk>/json_edit",
|
"collection/<int:pk>/json_edit",
|
||||||
views.GenericExamViews.exam_json_edit,
|
views.GenericExamViews.exam_json_edit,
|
||||||
|
|||||||
+8
-1
@@ -1050,7 +1050,12 @@ def collection_detail(request, pk):
|
|||||||
def collection_take(request, pk):
|
def collection_take(request, pk):
|
||||||
collection = get_object_or_404(CaseCollection, pk=pk)
|
collection = get_object_or_404(CaseCollection, pk=pk)
|
||||||
|
|
||||||
return render(request, "atlas/collection_take.html", {"collection": collection})
|
match collection.collection_type:
|
||||||
|
case "REP":
|
||||||
|
return render(request, "atlas/collection_take.html", {"collection": collection})
|
||||||
|
case "REV":
|
||||||
|
return render(request, "atlas/collection_review.html", {"collection": collection})
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@user_is_collection_author_or_atlas_editor
|
@user_is_collection_author_or_atlas_editor
|
||||||
@@ -1232,6 +1237,8 @@ def collection_take_overview(request, pk, cid, passcode):
|
|||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
|
||||||
|
def collection_case_view_review(request, pk, case_number):
|
||||||
|
return collection_case_view_take(request, pk, case_number, None, None)
|
||||||
|
|
||||||
def collection_case_view_take(request, pk, case_number, cid, passcode):
|
def collection_case_view_take(request, pk, case_number, cid, passcode):
|
||||||
collection = get_object_or_404(CaseCollection, pk=pk)
|
collection = get_object_or_404(CaseCollection, pk=pk)
|
||||||
|
|||||||
@@ -92,6 +92,7 @@
|
|||||||
User results emailed: {{exam.exam_results_emailed|default:"Never"}}<br/>
|
User results emailed: {{exam.exam_results_emailed|default:"Never"}}<br/>
|
||||||
<button id="email-results-button" title="Email results to users and their supervisors">Email user results</button>
|
<button id="email-results-button" title="Email results to users and their supervisors">Email user results</button>
|
||||||
<button id="email-results-check-button" title="Check the status of emailed results">Check email status</button>
|
<button id="email-results-check-button" title="Check the status of emailed results">Check email status</button>
|
||||||
|
<p>Note: currently only works with registered users</p>
|
||||||
</details>
|
</details>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user