nocontrols Posted May 6, 2016 Share Posted May 6, 2016 Hi, I have enabled Tax within WHMCS as well as enabled EU VAT Addon. Now I proceed to buy .de domain name. I have a German address. Configdomains page ask for my VAT ID which I provide. Then I click Continue to get on to the Shopping Cart page which add VAT @19% to my order total (even though I provided my VAT ID in the previous step) I click on 'Order Checkout' It brings me to the page where I enter credit card details and the amount that it says will be charged to my credit card, includes VAT. Is this expected behaviour? Shouldn't the Addon not include VAT for order total when I entered VAT ID on configdomain page? Does EU VAT Addon only kicks in after an order is paid for (i.e. once an invoice has been generated)? I am a bit confused as customer would have already paid tax by then as soon as he clicked 'Complete Order' on Order Checkout page. Any advice would be appreciated. Thx. 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted May 6, 2016 Share Posted May 6, 2016 the EU VAT Addon wouldn't ask for a VAT ID during the Domains Configuration stage of the order process - this is being requested by an entry in the additionaldomainsfields.php file. http://docs.whmcs.com/Domains_Configuration#TLD_Specific_Additional_Domain_Fields 0 Quote Link to comment Share on other sites More sharing options...
nocontrols Posted May 7, 2016 Author Share Posted May 7, 2016 you are right that VAT ID is being asked by additionaldomainfields. My understanding was that EU VAT Addon does the VAT ID Validation as well as automatically set client to tax exempt status if the ID is correct. However, I am not sure when does this check happens. Config domains page where a client enters VAT Tax ID on clicking proceed leads to order checkout page on which client enters his / her credit card details. My question is: Does the EU VAT ID Validation happens before user clicks Complete Order on the order checkout page or after? On my website, there are no errors, order checkout page shows Order Total including VAT (even though I entered correct VAT ID on config domains page) which means that as soon as the client clicks Complete Order, his / her credit card will get charged for VAT as well even though he / she should be tax exempt since VAT ID was entered. 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted May 7, 2016 Share Posted May 7, 2016 it should happen during the checkout process... however, it sounds as though you haven't added the custom client field as mentioned in the Tax documentation... http://docs.whmcs.com/Tax/VAT#Automatic_VAT_Number_Validation Automatic VAT Number Validation WHMCS can be setup to check the VAT number a user supplies during the order process - to validate it and automatically set tax exempt status for the client. To use this feature, you'll need to setup a custom field in Setup > Custom Client Fields as demonstrated below and then activate & configure the Official EU VAT Addon Module per these instructions: http://docs.whmcs.com/EU_VAT_Addon if you do that, and assign that custom field in the EU VAT Addon setup, then customers will be asked at checkout for their VAT ID - and if the addon is configured correctly, it should exempt those with valid IDs from being charged VAT. the point being that without that custom field, WHMCS won't know what the VAT number is - I know the customer has entered it previously (in the case of .de registrations), but that's for another purpose, not EU VAT validation. 0 Quote Link to comment Share on other sites More sharing options...
nocontrols Posted May 7, 2016 Author Share Posted May 7, 2016 Thx. for helping triangulate the issue. The Issue (as pointed out) is custom client field is not showing up on the order checkout page. I already had setup Custom field (VAT Number), checked 'Show on Order Form' and specified it within EU VAT Addon but didn't realized that what's showing up on configdomain page is not that. I am using standard cart and when I open checkout.tpl it does contain the foll. code: ----- {if $customfields} <div class="sub-heading"> <span>{$LANG.orderadditionalrequiredinfo}</span> </div> <div class="field-container"> <div class="row"> {foreach $customfields as $customfield} <div class="col-sm-6"> <div class="form-group"> <label for="exampleInputEmail1">{$customfield.name}</label> {$customfield.input} {if $customfield.description} <span class="field-help-text"> {$customfield.description} </span> {/if} </div> </div> {/foreach} </div> </div> {/if} ----- However, it is not showing up on the orderform. When I click continue on configdomain page, it takes me to ****/cart.php?a=view and from there to ****/cart.php?a=checkout on neither of those 2 pages, I see the custom field that I created. When I look inside tpl file, the above customfield is in checkout.tpl but there is no customfield code in viewcart.tpl 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted May 7, 2016 Share Posted May 7, 2016 when I look at standard_cart/checkout.tpl from v6.3.1, I see the following (which looks similar except for the label)... {if $customfields} <div class="sub-heading"> <span>{$LANG.orderadditionalrequiredinfo}</span> </div> <div class="field-container"> <div class="row"> {foreach $customfields as $customfield} <div class="col-sm-6"> <div class="form-group"> <label for="customfield{$customfield.id}">{$customfield.name}</label> {$customfield.input} {if $customfield.description} <span class="field-help-text"> {$customfield.description} </span> {/if} </div> </div> {/foreach} </div> </div> {/if} two thoughts - firstly, try it in another orderform template... the quick way would be to add &carttpl=modern to the end of your cart url; secondly, even if it wasn't assigned to the addon, the custom field should still be appearing... so assuming you haven't modified the templates in anyway, you could try unticking the "Show on Order Form" checkbox, saving and then tick it again and re-save... just to make sure the setting is correct in the database... if that fails, delete the custom field and add it again and then reassign it in the addon. 0 Quote Link to comment Share on other sites More sharing options...
nocontrols Posted May 7, 2016 Author Share Posted May 7, 2016 The issue is limited to logged in users. customfields code within Checkout.tpl kicks in only when user is not loggedin. As soon as a user logs in, the code does not display. I even tried putting the more generic customfield code in a different section of checkout.tpl but it still does not display. The 2 codes I tried are: A. {foreach key=num item=customfield from=$customfields} <tr><td class="fieldarea">{$customfield.name}</td><td>{$customfield.input} {$customfield.required}</td></tr> {/foreach} B. {foreach $customfields as $customfield} <div class="col-sm-6"> <div class="form-group"> <label for="customfield{$customfield.id}">{$customfield.name}</label> {$customfield.input} {if $customfield.description} <span class="field-help-text"> {$customfield.description} </span> {/if} </div> </div> {/foreach} in both case nothing displays when a user is loggedin. I also tried by putting {debug} on the first line of checkout.tpl When a user is not logged in, it shows: $customfields Smarty_Variable Object (3) ->value = Array (1) 0 => Array (10) id => "2" textid => "vat" name => "VAT" description => "Please enter your company's VAT ..." type => "text" input => "<input type="text" name="customfield[..." value => "" rawvalue => "" required => "" adminonly => "" ->nocache = false ->scope = "file:orderforms/standard_cart/checkou..." However, when a user is logged in, it does not display $customfields. Is it possible to display the customfield when a user is logged in? If not, is there some other way to validate VAT id for logged in user? Thx. 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted May 8, 2016 Share Posted May 8, 2016 The issue is limited to logged in users. oh if you'd told me you were logged in while testing, I could have told you that! when logged in, WHMCS assumes that it already has all the information and shows all fields as read-only - none of them can be edited. Is it possible to display the customfield when a user is logged in? If not, is there some other way to validate VAT id for logged in user? as you say, the $customfields array only has content when not logged in, so there is no point in trying to display the customfields in those circumstances as WHMCS doesn't have them to show - I suppose you could write an action hook to pass them if you wanted to, but it's not really necessary. there are at least two other ways that a VAT ID could be validated - one for the client, and one for you. when a client updates their profile (using 'Edit Account Details' from the logged in secondary menu - clientarea.php?action=details), they can edit the values of the custom fields (unless they're admin only) and it will update the database... though it's worth noting that ALL the required fields must be completed before the record is updated. if you enter an invalid VAT number, it will tell you - so '123456789' will be rejected; 'GB 927 7746 76' will be accepted... the slight quirk is if you enter a valid VAT ID, but miss out a required field, it will not store the valid ID and also stop showing the error message... I suppose that's a potential bug, so just be aware of it... you might want to tweak the template to display a message about it. the second way is similar and you can do it as an admin - just go to the client's profile in the admin area, click on the profile tab and you can enter/edit/remove it... it will be validated and should only saved if it is valid (or you're deleting an existing VAT number). 0 Quote Link to comment Share on other sites More sharing options...
LusoAloja Posted August 24, 2016 Share Posted August 24, 2016 Hello, I do apologize for Jump on this Thread, But i have some Questions. Is my understand that if you sell Digital goods to any EU country we need charge thee country VAT, However I believe that if the Custumer abroad, is ALSO vat register, he will not need to pay the vat. IE: Our company is MOSS vat register in UK, if we sell a customer in France, and he is a business and IS VAT register, he will be exempt, if we sell to the Final customer, then he will be charged at standard rate of 20%. Does the VAT module, does that or not really? 0 Quote Link to comment Share on other sites More sharing options...
Kian Posted August 25, 2016 Share Posted August 25, 2016 Correct. Only for clients with no VAT number (individuals, not companies) you have to apply the tax rate of their countries. For example let's suppose that you are an UK company. You will apply 20% to French, 22% to Italians, 19% to Germans etc. That said, EU VAT Addon allows you to specify a Client Custom Field to use for automatic validation of VAT numbers. There are also other modules in the Marketplace that allows you to comply to these rules even with more features. 0 Quote Link to comment Share on other sites More sharing options...
LusoAloja Posted August 25, 2016 Share Posted August 25, 2016 Correct. Only for clients with no VAT number (individuals, not companies) you have to apply the tax rate of their countries. Well that is my question, Does the module Charge VAT TO ALL Customers regardless if they are company (and have valid VAT number), or will he exempt the companies that are VAT register (and have a valid VAT number). The Module documentation is a bit grey on that 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted August 25, 2016 Share Posted August 25, 2016 https://forum.whmcs.com/showthread.php?95579-VATMOSS-amp-EU-VAT-changes&p=402439 It's necessary to differentiate between individuals and businesses. Individuals need to be charged VAT, whilst businesses do not. The EU VAT invoicing addon takes care of this by using the VAT ID number to automatically mark business users tax exempt: http://docs.whmcs.com/EU_VAT_Addon 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.