{% extends "vendor/manage/base.html" %}
{% load i18n %}

{% block vendor_content %}
<div class="container-fluid">

  <nav aria-label="breadcrumb">
    <!-- <ol class="breadcrumb"> -->
    <h1>{% trans 'Site Order History' %}</h1>
    <!-- </ol> -->
  </nav>
  <div class="row">
    <div class="col">
      <table class="table table-striped">

        <thead>
          <tr>
            <th scope="col">{% trans '#' %}</th>
            <th scope="col">{% trans 'Name' %}</th>
            <th scope="col">{% trans 'Status' %}</th>
            <th scope="col">{% trans 'Date' %}</th>
            <th scope="col">{% trans 'Currency' %}</th>
            <th scope="col">{% trans 'Total' %}</th>
          </tr>
        </thead>
        <tbody>
          {% for item in object_list %}
          <tr>
            <td><a class="text-primary" href="{% url 'vendor_admin:manager-order-detail' item.uuid %}">{{ item.pk }}</a>
            </td>
            <td>{{ item.get_invoice_display }}</td>
            <td>{{ item.get_status_display }}</td>
            <td>{{ item.created }}</td>
            <td>{{ item.get_currency_display }}</td>
            <td>${{ item.total|floatformat:2|default:"0.00" }}</td>
          </tr>
          {% empty %}
          <tr>
            <td>
              {% trans 'No Orders' %}
            </td>
          </tr>
          {% endfor %}
        </tbody>

      </table>

    </div>
  </div>
</div>
{% endblock %}