{% load i18n %} {% load humanize %} Invoice

From

{{ issuer_details.company }}
{{ issuer_details.address }}
{{ issuer_details.country }}, {{ issuer_details.postal }}
P: ({{ issuer_details.phone.country_code }}) {{ issuer_details.phone.national_number }}
{{ issuer_details.bank }}, {{ issuer_details.account }}
{% trans "VAT" %}:{{ issuer_details.vat_code }}
{{ issuer_details.email }}

{% trans "Invoice No." %} {{ invoice.number|upper }}

To

{{ invoice.customer.name }}
{% if invoice.customer.address %}
{{ invoice.customer.address }}
{% endif %} {% if invoice.customer.country and invoice.customer.postal %}
{{ invoice.customer.country }}, {{ invoice.customer.postal }}
{% endif %} {% if invoice.customer.phone_number %}
P: {{ invoice.customer.phone_number }}
{% endif %} {% if invoice.customer.bank_name and invoice.customer.bank_account %}
{{ invoice.customer.bank_name }}, {{ invoice.customer.bank_account }}
{% endif %} {% if customer.vat_code %}
{% trans "VAT" %}: {{ customer.vat_code }}
{% endif %}
{{ invoice.customer.email }}
{% trans "Invoice date" %}: {{ invoice.invoice_date|date:"Y-m-d" }}
{% trans "Due date" %}: {{ invoice.due_date|date:"Y-m-d" }}
{% trans "Invoice period" %}: {{ invoice.year }}-{{ invoice.month }}
{% regroup items|dictsort:"project_name" by project_name as project_list %} {% for project in project_list %} {% for item in project.list %} {% endfor %} {% endfor %}
Item Quantity Unit price Total price

{{ project.grouper }}

{{ item.name }}
{% trans "Start time" %}: {{ item.start | date:"Y-m-d H:i" }}. {% trans "End time" %}: {{ item.end | date:"Y-m-d H:i" }}.
{{ item.quantity }} €{{ item.unit_price | floatformat:2 | intcomma }} €{{ item.total | floatformat:2 | intcomma }}
{% if invoice.tax %} {% endif %}
{% trans "Subtotal" %} €{{ invoice.price | floatformat:2 | intcomma}}
{% trans "VAT" %} € {{ invoice.tax | floatformat:2 | intcomma}}
{% trans "TOTAL" %} €{{ invoice.total | floatformat:2 | intcomma}}