From 099d168ef496ac0aaa462d5f1321b1eb083b73a7 Mon Sep 17 00:00:00 2001 From: teutat3s Date: Mon, 7 Oct 2024 15:54:48 +0200 Subject: [PATCH] add check for user_company field, keep defaulting to user_name. To use this, set the "Company" field in the user profile --- momo.php | 27 ++++++++++++++++++++++----- 1 file changed, 22 insertions(+), 5 deletions(-) diff --git a/momo.php b/momo.php index b30a08f..d514677 100644 --- a/momo.php +++ b/momo.php @@ -104,9 +104,15 @@ footer .notes {
- user_name) . ' - ' . htmlsc($invoice->user_address_1) . ' - ' . htmlsc($invoice->user_zip) . ' ' . htmlsc($invoice->user_city); - ?> + user_company !== ""): ?> + user_company) . ' - ' . htmlsc($invoice->user_address_1) . ' - ' . htmlsc($invoice->user_zip) . ' ' . htmlsc($invoice->user_city); + ?> + + user_name) . ' - ' . htmlsc($invoice->user_address_1) . ' - ' . htmlsc($invoice->user_zip) . ' ' . htmlsc($invoice->user_city); + ?> +
@@ -159,7 +165,13 @@ footer .notes {
-
user_name); ?>
+
+ user_company !== "") : ?> + user_company); ?> + + user_name); ?> + +
user_vat_id) { echo '
' . trans('vat_id_short') . ': ' . $invoice->user_vat_id . '
'; } @@ -384,7 +396,12 @@ footer .notes {

Bitte überweisen Sie den Rechnungsbetrag innerhalb von days_overdue); ?> Tagen auf untenstehendes Konto:
- Inhaber: user_name; ?>
+ Inhaber: + user_company !== "") : ?> + user_company; ?>
+ + user_name; ?>
+ IBAN: user_iban; ?>
invoice_id); ?>