mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
/tu/{proposal_id}: Do not show voters if there are none
This was different than PHP. Signed-off-by: Kevin Morris <kevr@0cost.org>
This commit is contained in:
parent
04ab98907a
commit
97c1247b57
2 changed files with 7 additions and 5 deletions
|
@ -111,7 +111,7 @@ def render_proposal(request: Request,
|
|||
""" Render a single TU proposal. """
|
||||
context["proposal"] = proposal
|
||||
context["voteinfo"] = voteinfo
|
||||
context["voters"] = voters
|
||||
context["voters"] = voters.all()
|
||||
|
||||
participation = voteinfo.ActiveTUs / voteinfo.total_votes() \
|
||||
if voteinfo.total_votes() else 0
|
||||
|
|
|
@ -4,10 +4,12 @@
|
|||
<div class="box">
|
||||
{% include "partials/tu/proposal/details.html" %}
|
||||
</div>
|
||||
|
||||
<div class="box">
|
||||
{% include "partials/tu/proposal/voters.html" %}
|
||||
</div>
|
||||
|
||||
{% if voters %}
|
||||
<div class="box">
|
||||
{% include "partials/tu/proposal/voters.html" %}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="box">
|
||||
{% if error %}
|
||||
|
|
Loading…
Add table
Reference in a new issue