Hi,
I am using Magento 2.4.
The product price is 12.95 and from 12 items there is a 10% discount.
My calculation is:
$priceHelper = $objectManager->create('Magento\Framework\Pricing\Helper\Data');
$priceHelper->currency(($price*12)-($price*12*0.1), true, false);
My result is therefore 139.86 (which seems correct to me) but the cart is showing me 139.92 after adding 12 products...
So I have 2 questions:
- Is there any Magento functionality to get the final price for a given product, something like:
$finalPrice = $product->calculatePriceByQty($quantity);
- Why would the cart have this slightly different result? (I am not using any "Cart Price rule" or "Catalog Price Rule")
Thanks for any help or hint.
Solved! Go to Solution.
Hello @jeromeclic79eb
Hello @jeromeclic79eb
Thanks so much Sanjay! Yes, this makes sense now. In all the coding I was not even considering this option...