We need help with solving a VAT problem. We are required to charge a VAT for shipping based on the VAT of the items being delivered, we ship products with two different tax classes.
If someone is interested we are willing to pay to solve this issue. We use OC 2.2.0.0. with Intuitive shipping and some Isenselabs mods.
This is a basic explanation of how we need it to work.
Its not really a full mod with admin page etc. that I am asking for (I think...). Its a fairly small code change that when installed alters the way shipping VAT is calculated (or I could just buy the actual code and a pointer to where in which file to manually insert it).
VAT12 = Total VAT payed for all items with 12 % VAT.
VAT25 = Total VAT payed for all items with 25 % VAT.
The shipping VAT should then be a value weighted calculated VAT. The actual VAT payed total for all items.
A piece of candy 1$ at 12 % VAT -> total cost 1.12 $ and VAT12=0.12$
A pencil 1$ at 25 % VAT -> total cost 1.25$ and VAT = 0.25$
A paper 1$ at 25 % VAT -> total cost 1.25$ and VAT = 0.25$
VAT12 = 0.12 and VAT25 = 0.5
Total cost of products 3$ and total VAT payed 0.62$, the shipping VAT for the package sending the candy and the pencil and paper together is 0.62/3 = 20.67 %.
If shipping is 1$ then the total payed will be 1.12+1.25+1.25+1.21 = 4.83$ and the total VAT 0.83$. This need to influence the checkout both in payment and in visual.
In Zencart it was a matter of less than 10 lines of code. I looked at the code for VAT, cart/checkout and Shipping and it does not look impossible (but I have too bad grasp of the opencart structure (and perhaps PHP)) to make the change myself.
Brgs,
David
Veg Trading HB/vegshop.se
If someone is interested we are willing to pay to solve this issue. We use OC 2.2.0.0. with Intuitive shipping and some Isenselabs mods.
This is a basic explanation of how we need it to work.
Its not really a full mod with admin page etc. that I am asking for (I think...). Its a fairly small code change that when installed alters the way shipping VAT is calculated (or I could just buy the actual code and a pointer to where in which file to manually insert it).
VAT12 = Total VAT payed for all items with 12 % VAT.
VAT25 = Total VAT payed for all items with 25 % VAT.
The shipping VAT should then be a value weighted calculated VAT. The actual VAT payed total for all items.
A piece of candy 1$ at 12 % VAT -> total cost 1.12 $ and VAT12=0.12$
A pencil 1$ at 25 % VAT -> total cost 1.25$ and VAT = 0.25$
A paper 1$ at 25 % VAT -> total cost 1.25$ and VAT = 0.25$
VAT12 = 0.12 and VAT25 = 0.5
Total cost of products 3$ and total VAT payed 0.62$, the shipping VAT for the package sending the candy and the pencil and paper together is 0.62/3 = 20.67 %.
If shipping is 1$ then the total payed will be 1.12+1.25+1.25+1.21 = 4.83$ and the total VAT 0.83$. This need to influence the checkout both in payment and in visual.
In Zencart it was a matter of less than 10 lines of code. I looked at the code for VAT, cart/checkout and Shipping and it does not look impossible (but I have too bad grasp of the opencart structure (and perhaps PHP)) to make the change myself.
Brgs,
David
Veg Trading HB/vegshop.se
Hi,
Greetings!
I checked your post and can help you
Email me - deepvyas71@gmail.com or add on Skype - deepvyas71
Awaiting revert
Regards,
Deep
Greetings!
I checked your post and can help you
Email me - deepvyas71@gmail.com or add on Skype - deepvyas71
Awaiting revert
Regards,
Deep
Expert Opencart Developer & Designer | S: deepvyas71 | E: deepvyas71@gmail.com
Hello David,
I would be happy to help. Please mail me at: gabriel.cisin20@gmail.com and add me on skype: gabriel@cisinlabs.com to discuss more.
Looking forward to hearing you soon.
Regards
Gabriel
I would be happy to help. Please mail me at: gabriel.cisin20@gmail.com and add me on skype: gabriel@cisinlabs.com to discuss more.
Looking forward to hearing you soon.
Regards
Gabriel
Hello,
Please check your PM and let me know. I have relevant experience in an Opencart and ready to help you.
Looking forward to your reply.
Please check your PM and let me know. I have relevant experience in an Opencart and ready to help you.
Looking forward to your reply.
Extensions Developed for Opencart | Portfolio Opencart | info@elderberrytech.com
I'm just wondering if this was solved in the end as we have a client who may need this. Perhaps one of @ClearThinking 's extensions would do the job? Perhaps this one: https://www.opencart.com/index.php?rout ... on_id=6762
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
Unfortunately none of my extensions can do this, because it's an OpenCart limitation. OpenCart only allows a shipping method to pass back a single tax_class_id, so there's no way to calculate "partial VAT" based on the different items in the cart. The shipping rate needs to set a tax_class_id, which means it can only be one of the rates set in a Tax Class. It can't calculate its own tax cost and pass that onto the system.
To get this working you'd have to modify how OpenCart utilizes tax classes, and allow for multiple ones that affect a percentage of the cost passed back. Honestly, I tried this many years ago and it never worked properly, so I gave up. You're not going to find an extension for this, you'll have to write your own modifications to create it.
In some countries using the highest tax rate is also a valid solution, so my Ultimate Shipping extension does have a feature where it can pick the highest tax rate from applicable products. If there are products with different tax rates in the cart, it ends up using the highest rate's tax_class_id. It's not quite the same, but may suffice for some countries.
To get this working you'd have to modify how OpenCart utilizes tax classes, and allow for multiple ones that affect a percentage of the cost passed back. Honestly, I tried this many years ago and it never worked properly, so I gave up. You're not going to find an extension for this, you'll have to write your own modifications to create it.
In some countries using the highest tax rate is also a valid solution, so my Ultimate Shipping extension does have a feature where it can pick the highest tax rate from applicable products. If there are products with different tax rates in the cart, it ends up using the highest rate's tax_class_id. It's not quite the same, but may suffice for some countries.
Usually the VAT can be calculated this way:
1. all items have the same VAT > shipping use same VAT (e.g. 20%) .. the OpenCart way ..
2. some items have VAT A (e.g. 15%) and some VAT B (e.g. 20%) > shipping should be calculated on total sum of each items VAT class (and is finally a mixture of all)
3. some items have VAT A and some VAT B > shipping is currently calculated with the highest VAT class .. the OpenCart way ..
Tax authorities excepts case 3 - of course, because they get money more the want!
But the correct way should be case 2.
Example: basket has 3 items, 1 with net value 100 and tax 20% (VAT = 20,-), 2 with 10% and net value 50 (each 25) (VAT = 5,-).
Shipping should be calculated now this way:
150 is the total net value.
100 is 67% of the total net value (of 150), 50 = 33%.
Means, when the net value of shipping cost is 10, and we calculate the tax with both (10 & 20%), the figure will be (based on the percentage of total net amount per tax class):
The total gross value then is: 150 + 25 (VAT = 20 of 100 plus 5 of 50 > 25) 175,- plus shipping (10 + 1,64) = 186,64
Would be the shipping tax calculated as usually (all with the same (highest) tax), the total gross value would be: 187,- (175 + 10 + 2)
Calculating shipping taxes with OpenCart is possible this way, but not per default.
And yes, with an extension it is possible (nearly as described above).
Have such an option (type of calculation can be selected in the settings) in one of my extensions (since OC 1.5.x):
https://osworx.net/OpenCart-2.2.x/Custom-Shipping
1. all items have the same VAT > shipping use same VAT (e.g. 20%) .. the OpenCart way ..
2. some items have VAT A (e.g. 15%) and some VAT B (e.g. 20%) > shipping should be calculated on total sum of each items VAT class (and is finally a mixture of all)
3. some items have VAT A and some VAT B > shipping is currently calculated with the highest VAT class .. the OpenCart way ..
Tax authorities excepts case 3 - of course, because they get money more the want!
But the correct way should be case 2.
Example: basket has 3 items, 1 with net value 100 and tax 20% (VAT = 20,-), 2 with 10% and net value 50 (each 25) (VAT = 5,-).
Shipping should be calculated now this way:
150 is the total net value.
100 is 67% of the total net value (of 150), 50 = 33%.
Means, when the net value of shipping cost is 10, and we calculate the tax with both (10 & 20%), the figure will be (based on the percentage of total net amount per tax class):
Total VAT for shipping is now 1,64 (instead of applying only 20% of 10,- = 2,-)67% of 10 = 6,70 (calculated with 20%) >> 1,34
33% of 10 = 3,30 (calculated with 10%) >> 0,33
The total gross value then is: 150 + 25 (VAT = 20 of 100 plus 5 of 50 > 25) 175,- plus shipping (10 + 1,64) = 186,64
Would be the shipping tax calculated as usually (all with the same (highest) tax), the total gross value would be: 187,- (175 + 10 + 2)
Calculating shipping taxes with OpenCart is possible this way, but not per default.
And yes, with an extension it is possible (nearly as described above).
Have such an option (type of calculation can be selected in the settings) in one of my extensions (since OC 1.5.x):
https://osworx.net/OpenCart-2.2.x/Custom-Shipping
Full Stack Web Developer :: Dedicated OpenCart Development & Support DACH Region
Contact for Custom Work / Fast Support.
Thanks very much both, I'll contact you @OSWorx about it.
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
I was commissioned to create a solution to this problem that works with all shipping methods, so I now have an extension available that does this. It works with any shipping method installed in your OpenCart store, and will install as a separate modification than the actual shipping method itself. (OSWorX's extension should also solve this issue; if your rates can be set up within his extension then you wouldn't need my modification.)
If anyone is interested, you can check it out here: viewtopic.php?f=124&t=225574
If anyone is interested, you can check it out here: viewtopic.php?f=124&t=225574
Who is online
Users browsing this forum: alanjones, paulfeakins and 33 guests