Improve check for non-existent variables #2

Merged
b12f merged 1 commit from custom-field-check-with-isset into main 2024-08-15 14:17:20 +00:00

View file

@ -229,7 +229,7 @@ footer .notes {
<p class="invoice-meta"> <p class="invoice-meta">
Rechnungsnummer: <?php echo $invoice->invoice_number; ?><br /> Rechnungsnummer: <?php echo $invoice->invoice_number; ?><br />
<?php if ($custom_fields['invoice']['Leistungszeitraum-Anfang'] && $custom_fields['invoice']['Leistungszeitraum-Ende']): ?> <?php if (isset($custom_fields['invoice']['Leistungszeitraum-Anfang']) && isset($custom_fields['invoice']['Leistungszeitraum-Ende'])): ?>
Leistungszeitraum: Leistungszeitraum:
<?php echo date_from_mysql($custom_fields['invoice']['Leistungszeitraum-Anfang'], true); ?> <?php echo date_from_mysql($custom_fields['invoice']['Leistungszeitraum-Anfang'], true); ?>
- -
@ -237,7 +237,7 @@ footer .notes {
<?php endif; ?> <?php endif; ?>
</p> </p>
<?php if ($custom_fields['invoice']['Beschreibung']): ?> <?php if (isset($custom_fields['invoice']['Beschreibung'])): ?>
<p> <p>
<?php echo $custom_fields['invoice']['Beschreibung']; ?> <?php echo $custom_fields['invoice']['Beschreibung']; ?>
</p> </p>