Portal Engine Questions on portal engine and web parts.
Version 6.x > Portal Engine > Automatically apply tax class to product on creation? View modes: 
User avatar
Member
Member
Dlglsh - 6/12/2012 10:05:32 AM
   
Automatically apply tax class to product on creation?
Hi,

Is it possible to have a tax class automatically applied to a product when it is created? This would be more helpful than relying on remembering to go to the Tax Class tab and apply the tax as a second step.

Thanks,

Matt

User avatar
Member
Member
Dlglsh - 6/13/2012 9:49:09 AM
   
RE:Automatically apply tax class to product on creation?
I've been searching through CMS Desk and cannot find anywhere that allows automatically applying a Tax Class, such as VAT in the UK, to a product.

If there's a way of doing this in a .cs file somewhere then please let me know.

A last alternative would be to add a trigger on the SQL server db, but that would rely on knowing the SKUId so I would need to research the possibility of passing a value from the triggering table to the trigger.

Could setting a default tax class to a product be an option for future releases of Kentico?

Matt

User avatar
Member
Member
Dlglsh - 6/13/2012 10:19:05 AM
   
RE:Automatically apply tax class to product on creation?
Solved!

If you want/need to do the same thing, I added:
INSERT INTO COM_SKUTaxClasses ([SKUID], [TaxClassID]) VALUES (SCOPE_IDENTITY(), 2);

to the INSERT query under System tables > Ecommerce - SKU > Queries > insert

The second value of '2' in my code is the Id number of the tax class I am applying.

I hope that helps anyone.

Matt