dolibarr icon indicating copy to clipboard operation
dolibarr copied to clipboard

International invoice VAT for EU seller with EU customers

Open xabitrigo opened this issue 2 years ago • 5 comments

Bug

International buys should allow VAT types for both the origin and destination countries. According to this: https://ec.europa.eu/taxation_customs/business/vat/vat-e-commerce_en both cases are possible.

This can be activated via the option SERVICE_ARE_ECOMMERCE_200238EC (https://wiki.dolibarr.org/index.php/Setup_Other#Services_Module) , but it only seems to be working for predefined items, and not for free text products or services.

I think the problem may be in the line 5903 of tile htdocs/core/class/html.form.class.php

if (!isInEEC($societe_vendeuse) && (!is_object($societe_acheteuse) || (isInEEC($societe_acheteuse) && !$societe_acheteuse->isACompany()))) {

if I remove the "not" from the first isInEEC I can see the VAT for both countries

This is related to issue #12557

Environment Version

15.0.1

Environment OS

Ubuntu 20.04

Environment Web server

Apache

Environment PHP

7.4.29 FPM/FastCGI

Environment Database

PostgreSQL 12.10 (Ubuntu 12.10-0ubuntu0.20.04.1)

Environment URL(s)

No response

Expected and actual behavior

To see the VAT for both countries

Steps to reproduce the behavior

  • Install dolibarr
  • Set up the company as a Spanish company
  • Add a client from Italy
  • Create an Invoice
  • You should be able to use Italy 22% VAT, but it's not visible

Attached files

No response

xabitrigo avatar May 06 '22 06:05 xabitrigo