New: - Added the possibility to insert custom items on receipt upload in case the receipt couldn't be read. Changes: - Changed the display of the sum at the overview. You now see what you owe your establishment instead of just seeing how much you bought. - In addition the sum in the overview now accounts for membership time. You don't have to pay for something bought after you moved out for example.
41 lines
1.4 KiB
HTML
41 lines
1.4 KiB
HTML
{% extends "base.html" %}
|
|
|
|
{% block app_content %}
|
|
{% if establishment %}
|
|
{% if current_user.id == establishment.owner %}
|
|
<button type="button" class="btn btn-outline-dark px-2" data-bs-toggle="button" autocomplete="off"
|
|
onclick="window.location.href='{{ url_for('establishment.payment.insert_payment', establishment_id=establishment.id) }}'">
|
|
Zahlung hinzufügen
|
|
</button>
|
|
{% endif %}
|
|
{% endif %}
|
|
{% for user in results %}
|
|
<div class="card">
|
|
<button class="btn btn-primary" data-bs-toggle="collapse" data-bs-target="#b{{ user.id }}" aria-expanded="true">
|
|
<div class="card-header">
|
|
<h3>{{ user.email }}: {{ (user.sum | int)/100 }} €</h3>
|
|
</div>
|
|
</button>
|
|
{% if user.id %}
|
|
<div class="collapse" id="b{{ user.id }}">
|
|
{% for item_infos in user.item_infos %}
|
|
<div class="card-body">
|
|
<div class="col-sm-1"></div>
|
|
<div class="col">
|
|
<h4>{{ item_infos.date }}</h4>
|
|
{% for item in item_infos.item_list %}
|
|
<div class="row">
|
|
<div class="col-sm-1"></div>
|
|
<div class="col">
|
|
{{ item.amount }}x {{ item.name }} je {{ item.price/100 }} €
|
|
</div>
|
|
</div>
|
|
{% endfor %}
|
|
</div>
|
|
</div>
|
|
{% endfor %}
|
|
</div>
|
|
{% endif %}
|
|
</div>
|
|
{% endfor %}
|
|
{% endblock %} |