develop #67

Merged
samuel-p merged 6 commits from develop into main 2021-06-13 14:57:27 +00:00
4 changed files with 111 additions and 102 deletions
Showing only changes of commit bd591594e7 - Show all commits

View file

@ -1,35 +1,36 @@
{{locale}}
<table class="table">
<thead>
<tr>
<th>{{strings.date[locale]}}</th>
<th>{{strings.via[locale]}}</th>
<th>{{strings.from[locale]}}</th>
<th>{{strings.amount[locale]}}</th>
</tr>
</thead>
<tbody>
{% for donation in donations[0].donations %}
<tr>
<td>{{donation.date}}</td>
{% if donation.via == 'opencollective' %}
<td><a href="https://opencollective.com/sp-codes" rel="nofollow">Open Collective</a></td>
{% else %}
<td>{{strings[donation.via][locale]}}</td>
{% endif %}
{% if donation.from %}
<td>{{donation.from}}</td>
{% else %}
<td>***</td>
{% endif %}
<td>{{donation.amount | amount}} €</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<th colspan="3">{{strings.total[locale]}}</th>
<th>{{donations[0].donations | sum | amount}} €</th>
</tr>
</tfoot>
</table>
<div class="table-container">
<table class="table">
<thead>
<tr>
<th>{{strings.date[locale]}}</th>
<th>{{strings.via[locale]}}</th>
<th>{{strings.from[locale]}}</th>
<th>{{strings.amount[locale]}}</th>
</tr>
</thead>
<tbody>
{% for donation in donations[0].donations %}
<tr>
<td>{{donation.date}}</td>
{% if donation.via == 'opencollective' %}
<td><a href="https://opencollective.com/sp-codes" rel="nofollow">Open Collective</a></td>
{% else %}
<td>{{strings[donation.via][locale]}}</td>
{% endif %}
{% if donation.from %}
<td>{{donation.from}}</td>
{% else %}
<td>***</td>
{% endif %}
<td>{{donation.amount | amount}} €</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<th colspan="3">{{strings.total[locale]}}</th>
<th>{{donations[0].donations | sum | amount}} €</th>
</tr>
</tfoot>
</table>
</div>

View file

@ -1,38 +1,40 @@
{% for year in donations %}
<h2>{{year.year}}</h2>
<table class="table">
<thead>
<tr>
<th>{{strings.date[locale]}}</th>
<th>{{strings.via[locale]}}</th>
<th>{{strings.from[locale]}}</th>
<th>{{strings.amount[locale]}}</th>
</tr>
</thead>
<tbody>
{% for donation in year.donations %}
<tr>
<td>{{donation.date}}</td>
{% if donation.via == 'opencollective' %}
<td><a href="https://opencollective.com/sp-codes" rel="nofollow">Open Collective</a></td>
{% else %}
<td>{{strings[donation.via][locale]}}</td>
{% endif %}
{% if donation.from %}
<td>{{donation.from}}</td>
{% else %}
<td>***</td>
{% endif %}
<td>{{donation.amount | amount}} €</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<th colspan="3">{{strings.total[locale]}}</th>
<th>{{year.donations | sum | amount}} €</th>
</tr>
</tfoot>
</table>
<div class="table-container">
<table class="table">
<thead>
<tr>
<th>{{strings.date[locale]}}</th>
<th>{{strings.via[locale]}}</th>
<th>{{strings.from[locale]}}</th>
<th>{{strings.amount[locale]}}</th>
</tr>
</thead>
<tbody>
{% for donation in year.donations %}
<tr>
<td>{{donation.date}}</td>
{% if donation.via == 'opencollective' %}
<td><a href="https://opencollective.com/sp-codes" rel="nofollow">Open Collective</a></td>
{% else %}
<td>{{strings[donation.via][locale]}}</td>
{% endif %}
{% if donation.from %}
<td>{{donation.from}}</td>
{% else %}
<td>***</td>
{% endif %}
<td>{{donation.amount | amount}} €</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<th colspan="3">{{strings.total[locale]}}</th>
<th>{{year.donations | sum | amount}} €</th>
</tr>
</tfoot>
</table>
</div>
{% endfor %}

View file

@ -1,33 +1,35 @@
<table class="table">
<thead>
<tr>
<th>{{strings.name[locale]}}</th>
<th>{{strings.type[locale]}}</th>
<th>{{strings.provider[locale]}}</th>
<th>{{strings.amount[locale]}} / {{strings.month[locale]}}</th>
<th>{{strings.amount[locale]}} / {{strings.year[locale]}}</th>
</tr>
</thead>
<tbody>
{% for expense in expenses %}
<tr>
{% if expense.name[locale] %}
<td>{{expense.name[locale]}}</td>
{% else %}
<td>{{expense.name}}</td>
{% endif %}
<td>{{expense.type}}</td>
<td>{{expense.provider}}</td>
<td>{{expense.amount | amount}} €</td>
<td>{{expense.amount | year | amount}} €</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<th colspan="3">{{strings.total[locale]}}</th>
<th>{{expenses | sum | amount}} €</th>
<th>{{expenses | sum | year | amount}} €</th>
</tr>
</tfoot>
</table>
<div class="table-container">
<table class="table">
<thead>
<tr>
<th>{{strings.name[locale]}}</th>
<th>{{strings.type[locale]}}</th>
<th>{{strings.provider[locale]}}</th>
<th>{{strings.amount[locale]}} / {{strings.month[locale]}}</th>
<th>{{strings.amount[locale]}} / {{strings.year[locale]}}</th>
</tr>
</thead>
<tbody>
{% for expense in expenses %}
<tr>
{% if expense.name[locale] %}
<td>{{expense.name[locale]}}</td>
{% else %}
<td>{{expense.name}}</td>
{% endif %}
<td>{{expense.type}}</td>
<td>{{expense.provider}}</td>
<td>{{expense.amount | amount}} €</td>
<td>{{expense.amount | year | amount}} €</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<th colspan="3">{{strings.total[locale]}}</th>
<th>{{expenses | sum | amount}} €</th>
<th>{{expenses | sum | year | amount}} €</th>
</tr>
</tfoot>
</table>
</div>

View file

@ -270,6 +270,10 @@ pre {
}
}
.table-container {
overflow-y: auto;
}
table.table {
width: 100%;
margin-bottom: 16px;