Skip to content
Snippets Groups Projects
Commit 5b5f3326 authored by Zdenek Kubala's avatar Zdenek Kubala
Browse files

feature: show users who done sifrovacka

parent 41e998c5
No related branches found
No related tags found
No related merge requests found
This commit is part of merge request !9. Comments created here will be created in the context of that merge request.
......@@ -56,13 +56,7 @@
{% endfor %}
{% endif %}
{% else %}
<div class="alert alert--grey-125">
<span>
x <br>
{{sifrovacka_all_users}}
</span>
<!-- <span> Šifrovačka skončila a není možné se k ní přihlásit.</span>-->
</div>
<span> Šifrovačka skončila a není možné se k ní přihlásit.</span>
{% endif %}
{% else %}
<div class="alert alert--grey-125">
......@@ -70,6 +64,17 @@
</div>
{% endif %}
{% endif %}
{% if sifrovacka_all_users %}
<h1 class="head-alt-sm">Seznam úspěšných: </h1>
<div class="alert alert--grey-125">
<span>
-
{% for i in sifrovacka_all_users %}
{{i.user}} -
{% endfor %}
</span>
</div>
{% endif %}
</div>
{% comment %}
</br>
......
......@@ -150,8 +150,7 @@ def detail(request, sifrovacka_id):
sifrovacka_stage_count = sifrovacka_stages.count()
is_archived_sifrovacka = Sifrovacka.objects.filter(id = sifrovacka_id,
enddate_sifrovacka__lt = timezone.now())
sifrovacka_all_users = Participants.objects.filter(sifrovacka_id = \
sifrovacka_id).values('finished','user', 'id')
sifrovacka_all_users = Participants.objects.filter(sifrovacka_id = sifrovacka_id).exclude(finished=False)
if request.user.is_authenticated:
print(sifrovacka_all_users)
sifrovacka_all_user_current_stages= Participants.objects.filter(user = \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment