mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2026-04-06 07:47:53 +10:00
39 lines
1.7 KiB
HTML
39 lines
1.7 KiB
HTML
{% load i18n core_tags %}
|
|
{% if result_hidden_fields %}
|
|
<div class="hiddenfields">{# DIV for HTML validation #}
|
|
{% for item in result_hidden_fields %}{{ item }}{% endfor %}
|
|
</div>
|
|
{% endif %}
|
|
{% if results %}
|
|
<div class="results">
|
|
<table id="result_list">
|
|
<thead>
|
|
<tr>
|
|
{% for header in result_headers %}
|
|
<th scope="col"{{ header.class_attrib }}>
|
|
{% if header.sortable and header.sort_priority > 0 %}
|
|
<div class="sortoptions">
|
|
<a class="sortremove" href="{{ header.url_remove }}" title="{% translate "Remove from sorting" %}"></a>
|
|
{% if num_sorted_fields > 1 %}<span class="sortpriority" title="{% blocktranslate with priority_number=header.sort_priority %}Sorting priority: {{ priority_number }}{% endblocktranslate %}">{{ header.sort_priority }}</span>{% endif %}
|
|
<a href="{{ header.url_toggle }}" class="toggle {{ header.ascending|yesno:'ascending,descending' }}" title="{% translate "Toggle sorting" %}"></a>
|
|
</div>
|
|
{% endif %}
|
|
<div class="text">{% if header.sortable %}<a role="button" href="{{ header.url_primary }}">{{ header.text|capfirst }}</a>{% else %}<span>{{ header.text|capfirst }}</span>{% endif %}</div>
|
|
<div class="clear"></div>
|
|
</th>{% endfor %}
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for result in results %}
|
|
{% if result.form and result.form.non_field_errors %}
|
|
<tr><td colspan="{{ result|length }}">{{ result.form.non_field_errors }}</td></tr>
|
|
{% endif %}
|
|
{% with row_obj=cl.result_list|index:forloop.counter0 %}
|
|
<tr{% if row_obj and row_obj.search_rank is not None %} class="search-rank-{{ row_obj.search_rank }}"{% endif %}>{% for item in result %}{{ item }}{% endfor %}</tr>
|
|
{% endwith %}
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
{% endif %}
|