From 8c20974e5bb1a66e60194e557c17bc1424a3fdd7 Mon Sep 17 00:00:00 2001 From: Pek5892 Date: Fri, 3 May 2024 16:53:48 +0200 Subject: [PATCH] Fix template fatture --- templates/fatture/body.php | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/templates/fatture/body.php b/templates/fatture/body.php index 1f4f7d95b..61748ac8c 100755 --- a/templates/fatture/body.php +++ b/templates/fatture/body.php @@ -26,10 +26,7 @@ $prezzi_ivati = setting('Utilizza prezzi di vendita comprensivi di IVA'); // Creazione righe fantasma $autofill = new Util\Autofill(6, 40); -$rows_per_page = $fattura_accompagnatoria ? 13 : 18; -if (!empty($options['last-page-footer'])) { - $rows_per_page += 7; -} +$rows_per_page = $fattura_accompagnatoria ? 13 : 25; $autofill->setRows($rows_per_page); // Intestazione tabella per righe @@ -55,6 +52,13 @@ if (setting('Raggruppa attività per tipologia in fattura')) { $righe = $documento->getRighe(); } +if (count($righe) > 25) { + if (!empty($options['last-page-footer'])) { + $rows_per_page += 5; + $autofill->setRows($rows_per_page); + } +} + $num = 0; if (!setting('Visualizza riferimento su ogni riga in stampa')) {