Skip to content
Snippets Groups Projects
Verified Commit b154b946 authored by Nik | Klampfradler's avatar Nik | Klampfradler
Browse files

Use number field instead of transaction_id for invoic

parent 23a5fff2
No related branches found
No related tags found
No related merge requests found
......@@ -287,7 +287,7 @@ class EventRegistration(ExtensibleModel):
invoice, __ = Invoice.objects.get_or_create(for_content_type=ContentType.objects.get_for_model(self), for_object_id=self.pk, defaults={
"group": group,
"variant": "sepa" if self.accept_sepa else "transfer",
"transaction_id": f"HNF-{self.date_registered.strftime('%Y-%m')}-{self.id}",
"number": f"HNF-{self.date_registered.strftime('%Y-%m')}-{self.id}",
"currency": "EUR",
"total": self._get_total_amount()[0],
"tax": self._get_total_amount()[1],
......
......@@ -197,7 +197,7 @@
</address>
<article>
<date id="date">{{ invoice.created.date }}</date>
<h1>{% trans "Invoice" %} {{ invoice.transaction_id }}</h1>
<h1>{% trans "Invoice" %} {{ invoice.number }}</h1>
{% render_table invoice.purchased_items_table %}
{% render_table invoice.totals_table %}
......
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