Does anyone have any idea how I would access the customer_group_id and the products tax_class_id when the tax is being calculated in catalog/model/total/tax.php
Basically what I am trying to do is work out if a customer is in group x and the product has a tax class of y - don't charge tax for this product.
Its for a disability site and some products have funny rules regarding whether they can be tax exempt or not which I cannot really see how to do using the standard cart install.
I would greatly appreciate any help or advice that can be given
In case anybody is interested, I added the following after the tax has been calculated - its a nasty hack but seems to do what I needed, I have a customer group for exemption which has an ID of 11 and an exempt tax class which also has an ID of 11 - if the customer is in the exempt group AND the product has a tax class of exempt then set the tax amount to zero.
/* Added for VAT Exemption */
$vate_tclass=$key;
$vate_group=$this->customer->getCustomerGroupId();
if ($vate_group==11 && $vate_tclass==11 ){
$tax=0;
}
/* End of VAT exemption */
/* Added for VAT Exemption */
$vate_tclass=$key;
$vate_group=$this->customer->getCustomerGroupId();
if ($vate_group==11 && $vate_tclass==11 ){
$tax=0;
}
/* End of VAT exemption */
Who is online
Users browsing this forum: No registered users and 88 guests