{% extends "ox_layout.html" %}
{% block body %}

<div class="w3-light-grey w3-margin-bottom">
  <h2>Available Tasks</h2>
  <TABLE cellpadding="10">
    <TH>Name</TH>
    <TH>ID</TH>
    <TH>Status</TH>
    <TH>Result</TH>
    <TH>Finished at</TH>
    {% for item in tasks %}
    <TR>
      <TD>{{ item.task_name }}</TD>
      <TD>
	<A HREF="{{ url_for('ox_herd.show_task') + '?task_id='+item.task_id}}">
	  {{  item.task_id  }}
	</A>
      </TD>
      <TD>{{ item.task_status }}</TD>
      <TD>{{ item.return_value }}</TD>
      <TD>{{ item.task_end_utc }}</TD>
    </TR>
    {% endfor %}
  </TABLE>
</div>

{% endblock %}

{% extends "ox_layout.html" %}
{% block body %}

<div class="w3-light-grey w3-margin-bottom">
  <h2>Available Tasks</h2>
  <TABLE cellpadding="10">
    <TH>Name</TH>
    <TH>ID</TH>
    <TH>Status</TH>
    <TH>Result</TH>
    <TH>Finished at</TH>
    {% for item in tasks|sort(reverse=True, attribute='task_end_utc') %}
    <TR>
      <TD>{{ item.task_name }}</TD>
      <TD>
	<A HREF="{{ url_for('ox_herd.show_task') + '?task_id='+item.task_id}}">
	  {{  item.task_id  }}
	</A>
      </TD>
      <TD>{{ item.task_status }}</TD>
      <TD>{{ item.return_value }}</TD>
      <TD>{{ item.task_end_utc }}</TD>
    </TR>
    {% endfor %}
  </TABLE>
</div>

{% endblock %}

Sort by task_end_utc in descending order.
Sort by task_end_utc in descending order.
