Fix: Stornorechnung-Referenzzeile vereinheitlicht (Vorschau = PDF)
This commit is contained in:
parent
3b235db4f7
commit
3fcc4e6e26
3 changed files with 5 additions and 4 deletions
|
|
@ -114,7 +114,7 @@ class InvoiceController
|
|||
$originalrechnung = null;
|
||||
if (!empty($invoice['storno_of_id'])) {
|
||||
$originalrechnung = \Steuerkram\Database::fetchOne(
|
||||
'SELECT id, rechnungs_nr FROM invoices WHERE id = ?',
|
||||
'SELECT id, rechnungs_nr, rechnungs_datum FROM invoices WHERE id = ?',
|
||||
[(int)$invoice['storno_of_id']]
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ class PdfInvoiceService
|
|||
$stornoRefHtml = '';
|
||||
if ($isStorno && !empty($inv['original_rechnungs_nr'])) {
|
||||
$stornoRefHtml = '<div style="font-size:7pt;margin-top:2mm">'
|
||||
. 'Stornierung der Rechnung Nr. <strong>' . $h($inv['original_rechnungs_nr']) . '</strong>'
|
||||
. 'zu Rechnung Nr. <strong>' . $h($inv['original_rechnungs_nr']) . '</strong><br>'
|
||||
. 'vom ' . $fmtDate($inv['original_rechnungs_datum'] ?? '')
|
||||
. '</div>';
|
||||
}
|
||||
|
|
|
|||
|
|
@ -106,7 +106,8 @@ $badgeClass = match($invoice['status']) {
|
|||
<?= !empty($invoice['storno_of_id']) ? 'STORNORECHNUNG' : 'Rechnung' ?>
|
||||
<?php if (!empty($invoice['storno_of_id']) && !empty($originalrechnung)): ?>
|
||||
<div style="font-size:.65rem;margin-top:.3rem;font-weight:normal">
|
||||
Stornierung der Rechnung Nr. <strong><?= $h($originalrechnung['rechnungs_nr']) ?></strong>
|
||||
zu Rechnung Nr. <strong><?= $h($originalrechnung['rechnungs_nr']) ?></strong><br>
|
||||
vom <?= $h(View::formatDate($originalrechnung['rechnungs_datum'] ?? '')) ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue