{#- The swap target of the orders list, and also what the account detail page
shows for one account's orders. -#}
<div id="orders-table">
<div class="panel table-scroll">
<table>
<thead>
<tr>
<th>Order</th>
<th>Profile</th>
<th>Status</th>
<th>Identifiers</th>
<th>Created</th>
<th>Expires</th>
{#- The leaf's own notAfter, not the order object's `expires` beside
it (housekeeping, see `order.validity_seconds`): the date an
operator actually scans a list of orders for. -#}
<th>Certificate expires</th>
</tr>
</thead>
<tbody>
{% for order in page.items %}
<tr>
<td class="id-cell"><a href="/ui/orders/{{ order.id }}" title="{{ order.id }}"><code>{{ order.id }}</code></a></td>
<td><code>{{ order.profile }}</code></td>
<td>
<span class="badge {{ order.status }}">{{ order.status }}</span>
{#- Revocation is orthogonal to the order state machine: RFC 8555
defines no "revoked" status, so a revoked order stays `valid`
and this second badge is the only thing that says otherwise. -#}
{% if order.revokedAt %}<span class="badge revoked">revoked</span>{% endif %}
</td>
<td class="wrap-anywhere">
{%- for identifier in order.identifiers -%}
{% if not loop.first %}, {% endif %}{{ identifier.value }}
{%- endfor -%}
</td>
<td class="small"><time datetime="{{ order.createdAt }}">{{ order.createdAt }}</time><br><span class="muted">{{ order.createdAt | ago }}</span></td>
<td class="small"><time datetime="{{ order.expires }}">{{ order.expires }}</time><br><span class="muted">{{ order.expires | ago }}</span></td>
<td class="small">
{%- if order.certNotAfter -%}
<time datetime="{{ order.certNotAfter }}">{{ order.certNotAfter }}</time><br><span class="muted">{{ order.certNotAfter | ago }}</span>
{%- else -%}
<span class="muted">—</span>
{%- endif -%}
</td>
</tr>
{% else %}
<tr><td class="empty" colspan="7">No order matches.</td></tr>
{% endfor %}
</tbody>
</table>
</div>
{% include "partials/_pager.html" %}
</div>