billator/templates/bill.html.twig

121 lines
3.6 KiB
Twig
Raw Permalink Normal View History

2022-02-22 13:37:20 +01:00
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>
{% if (type is not defined) or type == 'bill' %}Facture{% endif %}
{% if type == 'estimate' %}Devis{% endif %}
</title>
2022-02-22 13:37:20 +01:00
<style>
{% include('./styles/main.css') %}
2022-02-22 13:37:20 +01:00
</style>
</head>
<body>
<div class="container">
{% if type == 'estimate' %}
<h2>Devis n°{{ id }}</h2>
{% endif %}
{% if (type is not defined) or type == 'bill' %}
2022-02-22 13:37:20 +01:00
<h2>Facture n°{{ id }}</h2>
{% endif %}
2022-02-22 13:37:20 +01:00
<div class="header">
<ul class="header-column provider">
<li>Au nom et pour le compte de :</li>
<li><b>{{ provider.name }}</b></li>
{% for line in provider.address %}
<li>{{ line }}</li>
{% endfor %}
<li><a href="telto:{{ provider.mobile }}">{{ provider.mobile_formatted }}</a></li>
<li><a href="mailto:{{ provider.email }}">{{ provider.email }}</a></li>
<li>SIRET : {{ provider.siret }}
<li>TVA intracom : {{ provider.tax_id }}</li>
<li>Code NAF : {{ provider.naf }}</li>
</ul>
<ul class="header-column customer">
<li>Adressé à :</li>
<li><b>{{ customer.name }}</b></li>
{% for line in customer.address %}
<li>{{ line }}</li>
{% endfor %}
<li>SIRET : {{ customer.siret }}
<li>TVA intracom : {{ customer.tax_id }}</li>
<li>Contact : {{ customer.contact.name }}</li>
</ul>
</div>
<p>
Le {{ date | format_datetime('full', 'none', locale='fr') }}, <br>
</p>
<p>
<b>Objet : {{ subject }}</b>
</p>
<br>
{% for category in categories %}
<div class="category">
<div class="row category-name">
<div class="col">
Tâche
</div>
<div class="col">
Durée (en jours)
</div>
</div>
<div class="row category-name">
{{ category.name }}
</div>
{% for task in category.tasks %}
<div class="row task">
<div class="col task-name">{{ task.name }}</div>
<div class="col task-duration">{{ task.days|format_number(locale='fr') }}</div>
</div>
{% endfor %}
<div class="row sub-total">
<div>
<div>Sous-total</div>
<div class="sub-total-amount">{{ category.total|format_number(locale='fr') }}</div>
</div>
</div>
</div>
{% endfor %}
<div class="summary">
<table class="summary-content">
<tr class="row">
<td>Total en jours</td>
<td>{{ summary.days_total|format_number(locale='fr') }} j</td>
</tr>
<tr class="row">
<td>Taux journalier en euros</td>
<td>{{ daily_rate }} €</td>
</tr>
<tr class="row">
<td>TVA (0 %)</td>
<td>0 €</td>
</tr>
<tr class="row">
<td>Total TTC</td>
<td>{{ summary.total|format_number(locale='fr') }} €</td>
</tr>
{% if summary.already_payed %}
<tr class="row">
<td>Déjà payé</td>
<td>{{ summary.already_payed|format_number(locale='fr') }} €</td>
</tr>
{% endif %}
<tr class="row">
<td>Solde</td>
<td><b>{{ summary.remaining|format_number(locale='fr') }} €</b></td>
</tr>
</table>
</div>
<div class="footer">
{% if (type is not defined) or type == 'bill' %}
2022-02-22 13:37:20 +01:00
<div>Coordonnées bancaires :</div>
<div class="banking">
<div>IBAN : FR76 1142 5009 0004 2337 9133 213</div> <div>BIC/SWIFT : CEPAFRPP</div>
</div>
{% endif %}
2022-02-22 13:37:20 +01:00
</div>
</div>
</body>
</html>