News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Wrong price: custom fields, two taxes

Started by webberry, February 16, 2012, 11:10:30 AM

Previous topic - Next topic

webberry

We have products with different sizes. For this we use custom fields.
We also have two different taxes for the products (Tax 8% and tax 2.5%).

Now the product price in the product detail is wrong, both taxes are counted together, although I only chose one tax for the product. The price in the shopping cart is correct.

Please take a loot at the print screens.

Can somebody help us? Is this a bug?

Thanks, Webberry



[attachment cleanup by admin]

rustle

I was encountering this issue
I solved it by making sure that the tax rules are identified in both a country and subsequent state.
Also in the billing info for the customer they must also select and a country and a state

If you do not do this VM has a tendency to apply multiple taxes when it should not

I hope this helps

webberry

Hi
Thanks for your reply.
Unfortunately it's still not working. I identified both with a country and state.
We've tried all the settings, with categories, without etc.
The problem exists only at the options.
Have you got an other idea?
Thanks

webberry


rustle

Hi Webberry
please read this post in full
http://forum.virtuemart.net/index.php?topic=98912.0

what you have to do is a template override to hide the multiple taxes in the cart until the  checkout process has been completed
then the correct tax will appear based upon the criteria you wold like

it took me awhile to get my head wrapped around it - but it works

Spiros Petrakis

I think this is a bug , it makes no sense to calculate custom fields by adding every tax that you create in your shop, when you have set a specific tax for the product.
Joomla templates and extensions development
https://www.yourgeek.gr

sebix

Is there a solution about this bug ? I spent a lot of time to try to fix this but i still have two additional taxes.

Milbo

I think also this is a bug, shouldnt be that way. Seems that the override for a product is not taken for calculation of the variant. Please tell me which custom you are using.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

sven.w

Quote from: Milbo on May 30, 2012, 19:05:13 PM
I think also this is a bug, shouldnt be that way. Seems that the override for a product is not taken for calculation of the variant. Please tell me which custom you are using.

Hello, we're having the same issue here (using the custom field type "cart variant").
Any idea if this issue has been adressed yet? (I'm just wondering as i haven't seen any similar ticket on dev.virtuemart.net)

regards sven

escapezone

Hello, we're having the same issue here (using the custom field type "cart variant").

Does anyone find a solution for this problem plz?

mdelreal

The same problem.

Until this bug is fixed, somebody knows how to hide the prices of custom fields

Thank
Manuel

easy

search this forum, it was somewhere here, you have to edit one file only

frogybella

VM 2.0.18a
Path : /administrator/components/com_virtuemart/models
File : customfields.php

Hi,

We have hacked this file to correct the problem this way :

Line 870-871 :
$price = self::_getCustomPrice($productCustom->custom_price, $currency, $calculator, (int)$product->product_tax_id);
$productCustom->text = JText::_ ($productCustom->custom_value) . ' ' . $price ;


We have added a new parameter to the function _getCustomPrice filled with the product's tax id. On second line, JText function has been added for translation support (nothing to do with the subject but it was nice to have it work too...).

Then on line 964, the beginning of the function become :
static function _getCustomPrice($customPrice, $currency, $calculator, $idtax) {
if ((float)$customPrice) {
$price = strip_tags ($currency->priceDisplay ($calculator->calculateCustomPriceWithTax ($customPrice, $idtax)));

We declare the new parameter and use it in the calculateCustomPriceWithTax function call.

It might not correct everything and every cases. For each product using the custom file you have to select the tax rate. A better solution could be found... but it works for us, and we can finish the project!

Hope this help,
Regards,
Frogybella

My website : www.fdbi.com