diff options
| author | Jan Tuomi <jans.tuomi@gmail.com> | 2024-03-31 14:47:31 +0300 |
|---|---|---|
| committer | Jan Tuomi <jan@jantuomi.fi> | 2024-12-21 19:43:13 +0200 |
| commit | 0b5b97c74803d1c8f06b380ad7c575109f9730ae (patch) | |
| tree | 027b6fed3d3abe453c7d5e74ab792f24e9e6368f /templates/poll_vote_list.html.j2 | |
| parent | 3964ea162bcad03de982cf76f5a30e64868508e7 (diff) | |
Fix list view form send
Diffstat (limited to 'templates/poll_vote_list.html.j2')
| -rw-r--r-- | templates/poll_vote_list.html.j2 | 52 |
1 files changed, 26 insertions, 26 deletions
diff --git a/templates/poll_vote_list.html.j2 b/templates/poll_vote_list.html.j2 index ef09af4..47a682f 100644 --- a/templates/poll_vote_list.html.j2 +++ b/templates/poll_vote_list.html.j2 @@ -1,35 +1,35 @@ -<div class="vote-list"> - {% for choice in choices %} - <div> - <label for="choice_{{ choice.id }}"> - <input type="checkbox" name="choice_{{ choice.id }}" id="choice_{{ choice.id }}"> - <strong> - {% include "poll_choice_datetime_range.html.j2" %} - </strong> - <span> - <i>{{ choice.votes_with_value(1) | length }} votes</i> - </span> - <div> - {% if choice.votes_with_value(1) | length != 0 %} - Voted by: {% for vote in choice.votes_with_value(1) %} - {{ vote.voter_name }}{% if not loop.last %}, {% endif %} - {% endfor %} - {% endif %} - </div> - </label> +<form action="/poll/{{ poll.id }}/vote" method="post"> + <div class="vote-list"> + {% for choice in choices %} + <div> + <label for="choice_{{ choice.id }}"> + <input type="checkbox" name="choice_{{ choice.id }}" id="choice_{{ choice.id }}"> + <strong> + {% include "poll_choice_datetime_range.html.j2" %} + </strong> + <span> + <i>{{ choice.votes_with_value(1) | length }} votes</i> + </span> + <div> + {% if choice.votes_with_value(1) | length != 0 %} + Voted by: {% for vote in choice.votes_with_value(1) %} + {{ vote.voter_name }}{% if not loop.last %}, {% endif %} + {% endfor %} + {% endif %} + </div> + </label> + </div> + <p></p> + {% endfor %} </div> - <p></p> - {% endfor %} -</div> -<div> - <form action="/poll/{{ poll.id }}/vote" method="post"> + <div> <label for="voter_name" hidden>Your name</label> <input type="text" name="voter_name" placeholder="Your name" required {% if prefill_voter_name %}value="{{ prefill_voter_name }}"{% endif %}> <input class="green" type="submit" value="Submit"> - </form> -</div> + </div> +</form> {% if managed_voter_names | length != 0 %} <br> |
