Skip to content
Snippets Groups Projects
Commit 5c01c0bb authored by ynerant's avatar ynerant
Browse files

Display 2 decimals in invoices

parent 979628b0
No related branches found
No related tags found
3 merge requests!104Beta,!98Morefront,!91Documents
Pipeline #8383 passed with warnings with stages
in 5 minutes and 8 seconds
...@@ -141,9 +141,8 @@ class InvoiceRenderView(LoginRequiredMixin, View): ...@@ -141,9 +141,8 @@ class InvoiceRenderView(LoginRequiredMixin, View):
invoice = Invoice.objects.filter(PermissionBackend.filter_queryset(request.user, Invoice, "view")).get(pk=pk) invoice = Invoice.objects.filter(PermissionBackend.filter_queryset(request.user, Invoice, "view")).get(pk=pk)
products = Product.objects.filter(invoice=invoice).all() products = Product.objects.filter(invoice=invoice).all()
# Informations of the BDE. Should be updated when the school will move.
invoice.place = "Gif-sur-Yvette" invoice.place = "Gif-sur-Yvette"
invoice.my_name = "BDE ENS Paris-Saclay" invoice.my_name = "BDE ENS Cachan"
invoice.my_address_street = "4 avenue des Sciences" invoice.my_address_street = "4 avenue des Sciences"
invoice.my_city = "91190 Gif-sur-Yvette" invoice.my_city = "91190 Gif-sur-Yvette"
invoice.bank_code = 30003 invoice.bank_code = 30003
......
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
\newcommand {\ListeProduits}{ \newcommand {\ListeProduits}{
{% for product in products %} {% for product in products %}
{{ product.designation|safe|escape_tex }} & {{ product.amount_euros|safe|escape_tex }} & {{ product.quantity|safe|escape_tex }} & {{ product.total_euros|safe|escape_tex }} \cr {{ product.designation|safe|escape_tex }} & {{ product.amount_euros|safe|escape_tex|floatformat:2 }} & {{ product.quantity|safe|escape_tex|floatformat:2 }} & {{ product.total_euros|safe|escape_tex|floatformat:2 }} \cr
{% endfor %} {% endfor %}
} }
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
\def\CodeGuichet{{"{"}}{{ obj.desk_code|stringformat:".05d" }}} \def\CodeGuichet{{"{"}}{{ obj.desk_code|stringformat:".05d" }}}
\def\NCompte{{"{"}}{{ obj.account_number|stringformat:".011d" }}} \def\NCompte{{"{"}}{{ obj.account_number|stringformat:".011d" }}}
\def\CleRib{{"{"}}{{ obj.rib_key|stringformat:".02d" }}} \def\CleRib{{"{"}}{{ obj.rib_key|stringformat:".02d" }}}
\def\IBAN{FR76\CodeBanque\CodeGuichet\NCompte\CleRib} \def\IBAN{FR76 \CodeBanque\CodeGuichet\NCompte\CleRib}
\def\CodeBic{{"{"}}{{ obj.bic }}} \def\CodeBic{{"{"}}{{ obj.bic }}}
\def\FactureNum {{"{"}}{{ obj.id }}} % Numéro de facture \def\FactureNum {{"{"}}{{ obj.id }}} % Numéro de facture
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment