django-constance/constance/templates/admin/constance/includes/results_list.html
2016-12-01 09:40:11 -08:00

34 lines
1.2 KiB
HTML

{% load admin_static admin_list i18n %}
<table>
<thead>
<tr>
<th><div class="text">{% trans "Name" %}</div></th>
<th><div class="text">{% trans "Default" %}</div></th>
<th><div class="text">{% trans "Value" %}</div></th>
<th><div class="text">{% trans "Is modified" %}</div></th>
</tr>
</thead>
{% for item in config_values %}
<tr class="{% cycle 'row1' 'row2' %}">
<th>
{{ item.name }} <div class="help">{{ item.help_text|linebreaksbr }}</div>
</th>
<td>
{{ item.default|linebreaks }}
</td>
<td>
{{ item.form_field.errors }}
{{ item.form_field }}
<br>
<a href="#" onClick="document.getElementById('{{ item.form_field.auto_id }}').value = '{{ item.default|escapejs }}'; return false;">Reset to default</a>
</td>
<td>
{% if item.modified %}
<img src="{% static 'admin/img/icon-yes.'|add:icon_type %}" alt="{{ item.modified }}" />
{% else %}
<img src="{% static 'admin/img/icon-no.'|add:icon_type %}" alt="{{ item.modified }}" />
{% endif %}
</td>
</tr>
{% endfor %}
</table>