<div class="tabs">
    <div class="tab">Diese Rechnung</div>
    <div class="tab">Alle offenen Rechnungen</div>
    <div class="tab">Dieses Fahrzeug</div>
    <div class="tab active">Debitor Historie</div>
</div>

<table class="table table-striped table-bordered">
    <thead>
        <tr>
            <th>Kunde_Nr</th>
            <th>Mahnung_Nr</th>
            <th>Mahndatum</th>
            <th>Mahnstufe</th>
            <th>Rechnung_Nr</th>
            <th>Rechnung_Datum</th>
            <th>Betrag</th>
            <th>Offen</th>
        </tr>
    </thead>
    <tbody>
        {% for row in forderungen_mahnungen %}
        <tr>
            <td>{{ row.Kunde_Nr }}</td>
            <td>{{ row.Mahnung_Nr }}</td>
            <td>{{ row.Mahnung_Datum|date_format }}</td>
            <td>{{ row.Mahnstufe }}</td>
            <td>{{ row.Beleg_Nr }}</td>
            <td>{{ row.Beleg_Datum|date_format }}</td>
            <td class="text-end">{{ row.Betrag|number_format }}</td>
            <td class="text-end">{{ row.Offen|number_format }}</td>
        </tr>
        {% endfor %}
    </tbody>
</table>