Page 1 of 1

Flat Rate and Tax Class Conflict

Posted: Sun Jul 26, 2020 1:08 am
by aainul
Hello OCians, Cheers to All.

I recently found an Issue... the issue is with Flat Rate (Shipping Method) and Tax Classes...
As I'm from India, So I've to create multiply tax classes because of GST (Goods and Services Tax)...
But after creating all Tax Classes, I found an Issue, to set Flat Rate we have to Set Tax Class there but you can select only one Tax Class,
So when I select a class there and another in product tax class, order placing show error.

Solution can be, if Tax Classes Excluded from Flat Rate, or Multiple Tax Classes can be selected in Flat Rate.
Lemme Give a scenario,
Product A cost 100 $ and with 12 % Tax, its total is 112 $, and Another product cost 200 $ and with tax of 18% its total is 236 $, so both the products have different Tax Classes (Tax 12 % and Tax 18 %)
Now when I activate Flat Shipping Rate to Tax classes 'None' shows error, and cant select all the classes,

Please Help. and sorry for Bad English.

Re: Flat Rate and Tax Class Conflict

Posted: Fri Jul 31, 2020 1:40 am
by johnp
Try X-Shipping Pro. I've used that and it's a very capable and flexible extension:

https://www.opencart.com/index.php?rout ... n_id=13705

Try the free version first though as that may give you what you need:

https://www.opencart.com/index.php?rout ... _license=0

Re: Flat Rate and Tax Class Conflict

Posted: Fri Jul 31, 2020 3:59 am
by Johnathan
You shouldn't be getting an error when you choose a single tax class. Is it an actual error, or just a miscalculation?

If it's just a miscalculation, then that would be because OpenCart does not work with multiple tax classes on a single shipping cost. It only lets you set a single tax_class_id for the shipping quote array, so you cannot use multiple tax classes. I've worked on this before, and it's too hard to do this within a shipping extension and get it working properly. You'd have to change how OpenCart core files work in order to use multiple tax classes on a single shipping rate.

If you're getting an actual error, post a screenshot of what you're seeing, and we'll see if we can offer you any advice.