[FIX] account_reports, l10n_it_reports: carryover fix

There is an issue with the Italian carryover, line vp14b.
Use case:
 - Month 1, have a value of 25 in this line => will trigger a carryover to line vp7
 - Month 2, add more value to vp14b so that it goes above 25.82.
   This will set the bound as None, and thus this will not impact the carryover.
This is wrong, because then the next month we will see a value of 25 in vp7
while it should be 0.

closes odoo/odoo#84938

X-original-commit: ffbc7af321a36d4fd0aebb94d7a636cb1fc34b88
Related: odoo/enterprise#24555
Signed-off-by: Olivier Colson <oco@odoo.com>
Signed-off-by: Nicolas Viseur <vin@odoo.com>
This commit is contained in:
Nicolas (vin)
2022-02-21 07:49:49 +00:00
parent 69e31db6ac
commit 9e27a1fd4a
+1 -1
View File
@@ -32,7 +32,7 @@ class AccountTaxReportLine(models.AbstractModel):
if amount_in_euro <= 25.82:
return (None, 0)
else:
return None
return (None, None)
def vp14_credit_carryover_condition(self, options, line_amount, carried_over_amount):
"""