Skip to content

Commit aa4f6dc

Browse files
changed the wording for non-authenticated users (#85)
1 parent 51e1559 commit aa4f6dc

1 file changed

Lines changed: 14 additions & 8 deletions

File tree

courses/templates/homework/homework.html

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,19 @@ <h2 class="mb-3 text-center">
3434
{% endif %}
3535

3636
{% if homework.is_scored %}
37-
{% if submission %}
38-
<div class="alert alert-success">
39-
<p>This homework is already scored. Your score is {{ submission.total_score }}.</p>
40-
</div>
37+
{% if is_authenticated %}
38+
{% if submission %}
39+
<div class="alert alert-success">
40+
<p>This homework is already scored. Your score is {{ submission.total_score }}.</p>
41+
</div>
42+
{% else %}
43+
<div class="alert alert-warning">
44+
<p>This homework is already scored. You didn't submit your answers.</p>
45+
</div>
46+
{% endif %}
4147
{% else %}
42-
<div class="alert alert-warning">
43-
<p>This homework is already scored. You didn't submit your answers.</p>
48+
<div class="alert alert-info">
49+
<p>This homework is already scored. <a href="{% url 'login' %}">Log in</a> to see your submission.</p>
4450
</div>
4551
{% endif %}
4652

@@ -59,7 +65,7 @@ <h2 class="mb-3 text-center">
5965

6066
{% if not is_authenticated %}
6167
<div class="mt-4 text-center">
62-
<p>Please <a href="{% url 'login' %}">log in</a> to submit your answers.</p>
68+
<p>Please <a href="{% url 'login' %}">log in</a> to access this homework.</p>
6369
</div>
6470
{% endif %}
6571

@@ -249,7 +255,7 @@ <h3 class="mb-3">Questions</h3>
249255
{% endif %}
250256
</button>
251257
{% else %}
252-
<p>Please <a href="{% url 'login' %}">log in</a> to submit your answers.</p>
258+
<p>Please <a href="{% url 'login' %}">log in</a> to access this homework.</p>
253259
{% endif %}
254260
</div>
255261
{% endif %}

0 commit comments

Comments
 (0)