[FIX] account_edi_ubl_cii: ubl2.0 import tax retrieving
During the work done on OIOUBL einvoice import, we saw that the `Percent` node is always located below a `TaxCategory` node in UBL 2.0. Task-id: 3420748 X-original-commit: 71d8bf93be472bdcf232e25e42f818e2df89cf8b Part-of: odoo/odoo#137758
This commit is contained in:
@@ -735,7 +735,7 @@ class AccountEdiXmlUBL20(models.AbstractModel):
|
||||
tax_nodes = tree.findall('.//{*}Item/{*}ClassifiedTaxCategory/{*}Percent')
|
||||
if not tax_nodes:
|
||||
for elem in tree.findall('.//{*}TaxTotal'):
|
||||
tax_nodes += elem.findall('.//{*}TaxSubtotal/{*}Percent')
|
||||
tax_nodes += elem.findall('.//{*}TaxSubtotal/{*}TaxCategory/{*}Percent')
|
||||
return self._import_fill_invoice_line_taxes(tax_nodes, invoice_line, inv_line_vals, logs)
|
||||
|
||||
def _correct_invoice_tax_amount(self, tree, invoice):
|
||||
|
||||
Reference in New Issue
Block a user