{% extends 'oscar/dashboard/layout.html' %}
{% load i18n %}

{% block body_class %}{{ block.super }} reports{% endblock %}
{% block title %}
    {% trans "Reports" %} | {{ block.super }}
{% endblock %}

{% block breadcrumbs %}
    <nav aria-label="breadcrumb">
        <ol class="breadcrumb">
            <li class="breadcrumb-item"><a href="{% url 'dashboard:index' %}">{% trans "Dashboard" %}</a></li>
            <li class="breadcrumb-item active" aria-current="page">{% trans "Reporting Dashboard" %}</li>
        </ol>
    </nav>
{% endblock %}

{% block headertext %}
    {% trans "Reporting dashboard" %}
{% endblock %}

{% block dashboard_content %}
    <div class="table-header">
        <h3><i class="fas fa-chart-bar"></i> {% trans "Reporting dashboard" %}</h3>
    </div>
    <div class="card card-body">
        <form id="generate_report_form" method="get" class="form-inline">
            {% include "oscar/dashboard/partials/form_fields_inline.html" with form=form %}
            <span class="form-group">
                {# data-loading-text is deliberately not used here so that the button doesn't stay disabled after a CSV download has started #}
                <button type="submit" id='generate_report' class="btn btn-primary">{% trans "Generate report" %}</button>
            </span>
        </form>
    </div>

    {% if description %}
        <div class="table-header">
            <h3><i class="fas fa-chart-bar"></i> {{ description }}</h3>
        </div>
    {% endif %}

    {% block report %}
    {% endblock %}

{% endblock dashboard_content %}
