From e225a0c35c34d7085a9dc1fc37c57fb78858be84 Mon Sep 17 00:00:00 2001 From: Frank Cools Date: Tue, 7 Oct 2025 15:47:09 +0200 Subject: [PATCH] Remove duplicate VAT result and rounding entries - Removed getVATResultEntry call (was creating 4456700) - Removed getRoundingEntry call (was creating duplicate entries) - All balancing now handled in getBalancingEntries method - Should now show only 4455100 with TD amount, no 4456700 --- core/class/declarationtva_pdf.class.php | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/core/class/declarationtva_pdf.class.php b/core/class/declarationtva_pdf.class.php index 1b0acf4..bf1da1e 100644 --- a/core/class/declarationtva_pdf.class.php +++ b/core/class/declarationtva_pdf.class.php @@ -1857,17 +1857,9 @@ class DeclarationTVA_PDF $line20_entries = $this->getLine20Accounts($declaration, $ca3_lookup); $entries = array_merge($entries, $line20_entries); - // Add VAT result on account 4456700 - $vat_result_entry = $this->getVATResultEntry($declaration, $ca3_lookup); - if ($vat_result_entry) { - $entries[] = $vat_result_entry; - } + // VAT result is now handled in getBalancingEntries method - // Add rounding difference - $rounding_entry = $this->getRoundingEntry($declaration, $ca3_lookup); - if ($rounding_entry) { - $entries[] = $rounding_entry; - } + // Rounding difference is now handled in getBalancingEntries method // Add balancing entry to ensure debits equal credits $balancing_entries = $this->getBalancingEntries($declaration, $entries);