|
|
|
@ -49,18 +49,18 @@
|
|
|
|
|
{% endfor %}
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
{% set sort_order = request.args.get('order', 'asc') == 'asc' %}
|
|
|
|
|
{% set sort_attribute = request.args.get('sort', 'last_changed') %}
|
|
|
|
|
{% set sort_order = sort_order or 'asc' %}
|
|
|
|
|
{% set sort_attribute = sort_attribute or 'last_changed' %}
|
|
|
|
|
{% set pagination_page = request.args.get('page', 0) %}
|
|
|
|
|
|
|
|
|
|
<div id="watch-table-wrapper">
|
|
|
|
|
<table class="pure-table pure-table-striped watch-table">
|
|
|
|
|
<thead>
|
|
|
|
|
<tr>
|
|
|
|
|
<th><input style="vertical-align: middle" type="checkbox" id="check-all"/> #</th>
|
|
|
|
|
<th></th>
|
|
|
|
|
{% set link_order = "desc" if sort_order else "asc" %}
|
|
|
|
|
{% set link_order = "desc" if sort_order == 'asc' else "asc" %}
|
|
|
|
|
{% set arrow_span = "" %}
|
|
|
|
|
<th><input style="vertical-align: middle" type="checkbox" id="check-all"/> <a class="{{ 'active '+link_order if sort_attribute == 'date_created' else 'inactive' }}" href="{{url_for('index', sort='date_created', order=link_order, tag=active_tag)}}"># <span class='arrow {{link_order}}'></span></a></th>
|
|
|
|
|
<th></th>
|
|
|
|
|
<th><a class="{{ 'active '+link_order if sort_attribute == 'label' else 'inactive' }}" href="{{url_for('index', sort='label', order=link_order, tag=active_tag)}}">Website <span class='arrow {{link_order}}'></span></a></th>
|
|
|
|
|
<th><a class="{{ 'active '+link_order if sort_attribute == 'last_checked' else 'inactive' }}" href="{{url_for('index', sort='last_checked', order=link_order, tag=active_tag)}}">Last Checked <span class='arrow {{link_order}}'></span></a></th>
|
|
|
|
|
<th><a class="{{ 'active '+link_order if sort_attribute == 'last_changed' else 'inactive' }}" href="{{url_for('index', sort='last_changed', order=link_order, tag=active_tag)}}">Last Changed <span class='arrow {{link_order}}'></span></a></th>
|
|
|
|
@ -69,8 +69,7 @@
|
|
|
|
|
</thead>
|
|
|
|
|
<tbody>
|
|
|
|
|
|
|
|
|
|
{% set sorted_watches = watches|sort(attribute=sort_attribute, reverse=sort_order) %}
|
|
|
|
|
{% for watch in sorted_watches %}
|
|
|
|
|
{% for watch in watches|sort(attribute=sort_attribute, reverse=sort_order == 'asc') %}
|
|
|
|
|
|
|
|
|
|
{# WIP for pagination, disabled for now
|
|
|
|
|
{% if not ( loop.index >= 3 and loop.index <=4) %}{% continue %}{% endif %} -->
|
|
|
|
|