UPDATES EasyBlog 6.0.11 Released! Update to the latest version now!

Helpdesk

Your Time
Our Time
Response Time
24 — 48 hours
We strive to provide the fastest ever response possible. However, we are not super beings.

Allow at least 24 — 48 hours
  Support is online
Our support specialists is available now. We will attend to you as soon as we can.
  Support is online

Always validate VAT-ID as a Business - Ignore Company Name

Tassos Marinos · ·
3:24 AM Wednesday, 18 November 2020
None
Steps to reproduce the issue.

1. Add an EU-VAT app to a country, eg: Spain
2. Go to the front-end on the checkout page
3. Select Spain in the Country dropdown
4. Enter a VAT ID BUT do not fill in the Company Name field (That field is supposed to be optional and can be ignored by the user)
[/list]

Actual Behavior
The VAT ID is not get validated as a Business and no validation error is shown because the Company Name is left blank. The user doesn't know that and can result in frustration.

Expected Behavior
The VAT ID should be validated as a Business and the validation error "VAT No. is invalid or not-registered" should be shown if the VAT ID is invalid without taking into account the Company Name field. The VIES Server requires only the VAT-ID to determine whether it's valid or not.

Fix
Update the com_payplans/themes/wireframe/checkout/default/company.js file on line 94 and replace the following


if ($('[data-pp-company-bizname]').val() && $('[data-pp-company-vatno]').val()) {


with


if ($('[data-pp-company-vatno]').val()) {


I am aware that I can fix this by overriding the company.js script in my template but I think it's a rather important issue that needs to be fixed in the core.
The replies under this section are restricted to logged in users or users with an active subscription with us