Open shalabhaggarwal opened 11 years ago
@shalabhaggarwal is there a taxes APi which would return all the taxes that are defined in magento ?
@sharoonthomas No, there is no such API available in the Core API of magento.
We might have to write one by ourselves or handle the taxes as and when they are imported from magento with sales.
@shalabhaggarwal would prefer if there is an API just as prestashop does it. It should make it easy to have a one2one mapping for the taxes ? That will be useful only if magento sales information gives us the ids of the taxes used in the order.
@sharoonthomas No, magento does not give us tax_id on complete sale order or on items. There is a tax_id available with address but I am not sure what use it is as tax comes with order items as simple amount value.
Yes, tax_id with address makes sens in case this is a VAT (because different kind of taxes may be charged to an order) because we have to deal with two distinct notions: the tax on products/item value itself and the application of the tax. The tax itself depends on the shop's location/country, it's application (on orders) depends on the customers country (case of sales for export to a foreign country or not) and the customers category (professional or private, especially in European union). I think tax_id should be imported with products and replace the default tax value defined by openERP accounting setting. Then tax_amount could be imported with orders as part of the Total.
A simple tax handling has been implemented with https://github.com/openlabs/magento_integration/commit/69b63062639562092c359ec29a2520d8211c14e8
This handles taxes coming in with simple products on sales but this does not work for bundled products right now.
Nice, thank you. I'll test it at the end of the week and make a feedback here. Have you seen that magento re-factored the tax calculation in the just released 1.8 ? http://www.magentocommerce.com/blog/comments/magento-community-edition-one-eight-now-available/
Right now the taxation is not handled by the connector. This should be handled and taxes should be imported correctly on sales.