customize invoices page (#8210)
This commit is contained in:
parent
55466aa73f
commit
8beb0b820c
|
@ -0,0 +1,29 @@
|
|||
<div id="content">
|
||||
<div id="appbar">
|
||||
<h2>
|
||||
Facture numéro {{ item.display_id }}
|
||||
</h2>
|
||||
<div id="item">
|
||||
<form action="{% url 'lingo-pay' %}" method="POST">
|
||||
<h4>Libellé {{ item.subject }}
|
||||
</h4>
|
||||
<p>Montant total {{item.total_amount }}€
|
||||
</p>
|
||||
{% if item.amount %}
|
||||
<p>Montant restant à payer: {{ item.amount }}€
|
||||
</p>
|
||||
{% endif %}
|
||||
<p>Emise le {{ item.creation_date|date:"SHORT_DATE_FORMAT" }}</p>
|
||||
{% if item.payment_date %}
|
||||
<p>Payée le {{ item.payment_date|date:"SHORT_DATE_FORMAT" }}</p>
|
||||
{% endif %}
|
||||
{% if item.amount %}
|
||||
{% csrf_token %}
|
||||
<input type="hidden" name="regie" value="{{ regie.pk }}" />
|
||||
<input type="hidden" name="item" value="{{ item.id }}" />
|
||||
<button>Payer</button>
|
||||
{% endif %}
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,37 @@
|
|||
{% load i18n %}
|
||||
|
||||
<h3>{{ title|safe }}</h3>
|
||||
{% if items %}
|
||||
<table id="items">
|
||||
<thead>
|
||||
<tr>
|
||||
<td>Numéro</td>
|
||||
<td>Libellé</td>
|
||||
<td>Date d'émission</td>
|
||||
<td>Montant(TTC)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for item in items %}
|
||||
<tr class="{% cycle 'lightgrey' 'white' %}">
|
||||
<td>{{ item.display_id }}</td>
|
||||
<td>{{ item.subject }}</td>
|
||||
<td>{{ item.creation_date|date:"SHORT_DATE_FORMAT" }}</td>
|
||||
<td>{% blocktrans with amount=item.total_amount %}
|
||||
{{ amount }}€
|
||||
{% endblocktrans %}
|
||||
</td>
|
||||
<td>
|
||||
<a href="{% url 'view-item' regie_id=item.regie.pk item_id=item.id %}" rel="popup" class="icon-view">Voir</a>
|
||||
{% if item.has_pdf %} /
|
||||
<a href="{% url 'download-item-pdf' regie_id=item.regie.pk item_id=item.id %}" class="icon-pdf">Télécharger</a>
|
||||
{% endif %}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% else %}
|
||||
Aucune facture
|
||||
{% endif %}
|
Reference in New Issue