Taxes per tax identifier

Tryton already provides the possibility of defining several tax identifiers per company (party) because in europe a company located in country A exceding a certain amount of sales to country B must have a VAT for the country B. Also invoices to that country must use the taxes of country B.

Recent releases also include a many2one to the tax identifier in invoices.

The problem is that configuring taxes per country is complex.

Ideally one could say that for product P, we define its tax for country A and then have a Tax Rule that converts it to country’s B Tax when required.

Unfortunately it can happen that for a product P1, country A may require to use a Reduced VAT Rate, whereas country B may require to use a Normal VAT Rate. For another product both countries may apply a Reduced VAT Rate.

Managing that with categories would require to have as many “source” taxes to be supplied to the tax rule as combinations of VAT Rates the company manages.

So I’m searching for alternatives to solve this issue.

It seems to me that one possibility would be to use an “account_categories” o2m field in products (instead of the account_category m2o that exists nowadays) with the following fields:

  • Product
  • Product Category
  • Tax Identifier

The latter could be optional, so it could behave as a MatchMixin. Alternatively we could use the Country instead ot the Tax Identifier.

Another possibility would be to add the “Product Category” field to Tax Rules, although I’m afraid we would, again, be in the situation of creating as many categories as combinations of taxes and countries there exist.

Thoughts? Ideas?

I do not think there are so many cases where a product is considered differently by countries.
I think they can be managed with a special rule on the tax rules.

Here is one idea:

Maybe you could specify on each tax the country (or list of countries) where they are used.

On the account_category you will add all the taxes that may be applicable for this product.

Then you can override the taxes_used property to filter only the taxes applicable depending on the country of the document.

For me, the major flaw of such design is that you can not be sure that all categories have all the taxes for all the countries. I still thing it is better to use tax rule,even if the wrong substitution is done, than having no taxes applied.

Using the wrong substitution is bad too.

What we do to prevent having invoice lines without taxes is using the account_invoice_taxes_required module.

But it is less error prone because you have the general rule that always applies. Because I’m pretty sure that the exception cases occur less than the general case.

But there are legitimate case where no taxes is allowed. Also such validation prevents to create incomplete draft invoice.