This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% load consenta_utils %} | |
{% with item=qs|index:widget.index %} | |
<div class="col-md-3 "> | |
<div class="panel purpose panel-default {% if widget.attrs.checked %}panel-primary{% endif %}" | |
style="cursor: pointer;"> | |
<div class="panel-heading "> | |
<!-- this is the standard for the checkbox from django . i suggest to hide this in the class--> | |
<!-- the click on the div .panel checks the checbox (see js) --> | |
<input type="checkbox" | |
name="{{ widget.name }}" | |
{% if widget.value != None %} | |
value="{{ widget.value|stringformat:'s' }}" | |
{% endif %} | |
{% for name, value in widget.attrs.items %}{% if value is not False %} | |
{{ name }}{% if value is not True %}="{{ value|stringformat:'s' }}"{% endif %} | |
{% endif %}{% endfor %}/> | |
</div> | |
<div class="panel-body"> | |
{{ item.description }} | |
</div> | |
</div> | |
</div> | |
{% endwith %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment