This repository has been archived on 2023-02-21. You can view files and clone it, but cannot push or open issues or pull requests.
portail-citoyen/portail_citoyen/apps/passerelle_register_plugin/templates/passerelle_register_plugin/plugin.html

40 lines
1.4 KiB
HTML

{% load i18n %}
<div id="passerelle-register-plugin-{{ instance.id }}" class="passerelle-register-plugin">
{{ form.non_field_errors }}
{% for field in form %}
{{ field.errors }}
{% endfor %}
<form method="post">
{% csrf_token %}
<table id="passerelle-register-plugin-table-{{ instance.id }}">
<thead>
<tr>
<td>{% trans "Name" %}</td>
{% for choice in form.all_choices %}
<td id="passerelle-register-plugin-header-{{choice|slugify}}-{{instance.id}}" class="passerelle-register-plugin-header-{{choice|slugify}}">
{{ choice }}
</td>
{% endfor %}
</tr>
</thead>
<tbody>
{% for field in form %}
<tr class="{% for checkbox in field %}{% if checkbox.is_checked %}passerelle-register-plugin-checked-{{ checkbox.choice_value|slugify }} {% endif %}{% endfor %}">
<td><label>{{ field.label }}</label></td>
{% for choice in form.all_choices %}
{% for checkbox in field %}
{% if checkbox.choice_value == choice %}
<td>{{ checkbox.tag }}</td>
{% endif %}
{% endfor %}
{% endfor %}
</tr>
{% endfor %}
</tbody>
</table>
<input type="submit" name="{{ submit_name }}" value="{{ submit_value }}"/>
</form>
</div>