Sort members alphabetically in the new bill form.

Fixes #333
This commit is contained in:
Alexis Métaireau 2018-08-05 21:09:56 +02:00
parent 67de8c3b35
commit 4dc9c3a926

View file

@ -101,7 +101,7 @@
<div class="controls col-9">
<ul id="payed_for" class="inputs-list">
<p><a href="#" id="selectall" onclick="selectall()">{{ _("Select all") }}</a> | <a href="#" id="selectnone" onclick="selectnone()">{{_("Select none")}}</a></p>
{% for key, value, checked in form.payed_for.iter_choices() %}
{% for key, value, checked in form.payed_for.iter_choices() | sort(attribute='1') %}
<p class="form-check"><label for="payed_for-{{key}}" class="form-check-label"><input name="payed_for" type="checkbox" {% if checked %}checked{% endif %} class="form-check-input" value="{{key}}" id="payed_for-{{key}}"/><span>{{value}}</span></label></p>
{% endfor %}
</ul>