Is there any way to customize VAT/Tax in ucommerce.
My requirement is , Apply 0 percentage VAT
But,if customer has selected "Utah" state in shipping address then only apply the VAT.
I have searched out for it and got following replies
I have followed these three links , but it's can not full-fill my requirements.
I have set VAT Rate in price group then trying to make it zero if "Utah" state is not selected.
Please point me out where I'm misleading.
Here is my code snippet,
public class CalculateTaxService : ITaxService
{
public Money CalculateTax(UCommerce.EntitiesV2.PriceGroup priceGroup, Money amount)
{
//Not getting what to do here....
var currency = UCommerce.Runtime.SiteContext.Current.CatalogContext.CurrentCatalog.PriceGroup.Currency;
var taxRate = 0;//priceGroup.VATRate; Here i changed VAT Rate for test purpose.
return new Money(amount.Value * taxRate, currency);
}
public Money CalculateTax(UCommerce.EntitiesV2.Product product, UCommerce.EntitiesV2.PriceGroup priceGroup, Money unitPrice)
{
//Not getting desired output by doing this also....
var currency = UCommerce.Runtime.SiteContext.Current.CatalogContext.CurrentCatalog.PriceGroup.Currency;
var incTax = unitPrice.Value;
var taxRate = 0;// priceGroup.VATRate; Here i changed VAT Rate for test purpose.
var tax = incTax * taxRate;
return new Money(tax, currency);
}
}
I have Changed basket.config as below
<component id="TaxService"
service="UCommerce.Catalog.ITaxService, UCommerce"
type="MyNamespaceHere.CalculateTaxService,MyNamespaceHere"
lifestyle="Singleton"/>
Calculate VAT/Tax in uCommerce
Hello,
Is there any way to customize VAT/Tax in ucommerce. My requirement is , Apply 0 percentage VAT But,if customer has selected "Utah" state in shipping address then only apply the VAT. I have searched out for it and got following replies
I have followed these three links , but it's can not full-fill my requirements. I have set VAT Rate in price group then trying to make it zero if "Utah" state is not selected. Please point me out where I'm misleading. Here is my code snippet,
Please help me out this problem.
is working on a reply...