<table class='table table-striped table-condensed' id='po-table' {% if toolbar %}data-toolbar='{{ toolbar }}'{% endif %}>
    <thead>
    <tr>
        <th data-field='company' data-searchable='true'>Company</th>
        <th data-field='reference' data-searchable='true'>Order Reference</th>
        <th data-field='description' data-searchable='true'>Description</th>
        <th data-field='status'>Status</th>
        <th data-field='items'>Items</th>
    </tr>
    </thead>
    <tbody>
    {% for order in orders %}
    <tr>
        <td>{% include "hover_image.html" with image=order.supplier.image hover=True %}<a href="{{ order.supplier.get_absolute_url }}purchase-orders/">{{ order.supplier.name }}</a></td>
        <td><a href="{% url 'purchase-order-detail' order.id %}">{{ order }}</a></td>
        <td>{{ order.description }}</td>
        <td>{% include "order/order_status.html" %}</td>
        <td>{{ order.lines.count }}</td>
    </tr>
    {% endfor %}
    </tbody>
</table>