Add a footer and a second text field to invoices

Also, move to using localized strings for Invoice.additional_text
settings for consistency.
This commit is contained in:
Tobias Kunze
2016-08-22 19:05:11 +02:00
parent 157a16810d
commit 5f401f17d8
5 changed files with 68 additions and 10 deletions

View File

@@ -275,11 +275,24 @@ class InvoiceSettingsForm(SettingsForm):
help_text=_("Will be printed as the sender on invoices. Be sure to include relevant details required in "
"your jurisdiction (e.g. your VAT ID).")
)
invoice_additional_text = forms.CharField(
widget=forms.Textarea(attrs={'rows': 5}), required=False,
invoice_introductory_text = I18nFormField(
widget=I18nTextarea,
required=False,
label=_("Introductory text"),
help_text=_("Will be printed on every invoice above the invoice rows.")
)
invoice_additional_text = I18nFormField(
widget=I18nTextarea,
required=False,
label=_("Additional text"),
help_text=_("Will be printed on every invoice below the invoice total.")
)
invoice_footer_text = I18nFormField(
widget=I18nTextarea,
required=False,
label=_("Footer"),
help_text=_("Will be printed centered and in a smaller font at the end of every invoice page.")
)
invoice_language = forms.ChoiceField(
widget=forms.Select, required=True,
label=_("Invoice language"),