[FIX] account: fix bug when opening a misc journal entry
Before this commit, opening a misc journal entry resulted in an error because we tried to compute the tax totals as if it was an invoice. This commit ignores the computation of these tax totals in case we have a misc journaly entry. opw-2946634 closes odoo/odoo#97600 Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
This commit is contained in:
@@ -159,6 +159,8 @@ class LegacyTaxTotalsComponent extends AbstractFieldOwl {
|
||||
}
|
||||
|
||||
_computeTotalsFormat() {
|
||||
if (!this.totals.value) // Misc journal entry
|
||||
return;
|
||||
let amount_untaxed = this.totals.value.amount_untaxed;
|
||||
let amount_tax = 0;
|
||||
let subtotals = [];
|
||||
|
||||
Reference in New Issue
Block a user