VirtueMart Forum

VirtueMart 2 + 3 + 4 => Product pricing => Topic started by: baroen on June 06, 2020, 20:56:49 PM

Title: targeted final price not 'available'
Post by: baroen on June 06, 2020, 20:56:49 PM
When I enter my products final price, check 'calculate base price' and hit Save, another final price calculated then what I entered.

Case:
I want to price my product at €13,50. When I enter this the base price is being calculated at € 12.38532 and the final price is set to €13,51
I searched the baseprice tipping point:
when I set it to 12.3849 the final price is 13,49.
when I set it to 12.385 the final price is 13,51.

I use only one calculation rule on this product 9% VAT. That is configured:
VatTax/ VAT per product | +% | 9.00

I noticed this after upgrading to VM 3.8.2 (10325)
Joomla 3.9.18

Any help would be appreciated.
Title: Re: targeted final price not 'available'
Post by: Jörgen on June 06, 2020, 21:38:55 PM
You have calculations set with ONLY 2 decimals, hence the seemingly errounous calculations.

You need more decimals for Your calculations.

Jörgen @ Kreativ Fotografi
Title: Re: targeted final price not 'available'
Post by: baroen on June 07, 2020, 10:34:03 AM
Thanks, I set Baseprice rounding to 4.  :)
Now the price shows fine.
Should I set all prices to 4 digits (apart from the salesprice) to ensure correct calculation?
Title: Re: targeted final price not 'available'
Post by: Jörgen on June 07, 2020, 10:49:20 AM
I would make some tests, I do not use any rounding  (-1).
But at the end of the day only Your mix of products (prices, quantities etc) can decide how the result will be in the invoice. Small prices and large quantities can make rounding differences very large.

Jörgen @ Kreativ Fotografi
Title: Re: targeted final price not 'available'
Post by: GJC Web Design on June 07, 2020, 11:29:20 AM
In most cases no rounding as Jörgen says is the most appropriate..  with of course your currency config set to 2 decimals etc to control display