VirtueMart Forum

VirtueMart 2 + 3 + 4 => Product pricing => Topic started by: bunglehaze on April 05, 2018, 14:27:46 PM

Title: Display price before discount overrides
Post by: bunglehaze on April 05, 2018, 14:27:46 PM
Hey all, I am using the catproduct extension to show my products in a table and have as part of the addon hidden the prices from the ontop and addtocart positions on VM 3.2.12

However, one limitation the extension has is that I cannot display the price before any discounts, only the final prices selected. As a result I now want to add a line to the default product page that will show MSRP: [and the price before discount price]

<?php echo $this->product->prices['salesPrice']  ?> Shows the discounted price, but I am unsure what the price description is for the price before discount with tax instead of salesPrice.

If anyone could help I would appreciate it.
Title: Re: Display price before discount overrides
Post by: lausianne on April 05, 2018, 20:07:02 PM
How about basePriceWithTax? (just a guess)

In .\administrator\components\com_virtuemart\helpers\currencydisplay.php I found this:

$priceNames = array('basePrice','variantModification','basePriceVariant',
   'basePriceWithTax','discountedPriceWithoutTax', 'discountedPriceWithoutTaxTt',
   'salesPrice', 'salesPriceTt', 'priceWithoutTax', 'priceWithoutTaxTt',
   'salesPriceWithDiscount','discountAmount','discountAmountTt','taxAmount', 'taxAmountTt','unitPrice');
Title: Re: Display price before discount overrides
Post by: bunglehaze on April 06, 2018, 10:45:01 AM
Yeah, I have tried the variants in the prices and they all seem to just display the sale price. It's an odd one
Title: Re: Display price before discount overrides
Post by: Jörgen on April 08, 2018, 10:27:08 AM
Do You mean this extension ?

https://extensions.virtuemart.net/product/products/catproduct-detail (https://extensions.virtuemart.net/product/products/catproduct-detail)

Post a support ticket or speak to the developer.

regards

Jörgen@ Kreativ Fotografi
Title: Re: Display price before discount overrides
Post by: bunglehaze on April 16, 2018, 17:02:11 PM
Just a quick update for those with the same issue. It was a simple setup issue in that my overrides on pricing were +/-% margin. I just changed it to DBtax (price modifier before tax) and the line I added changed to the correct MSRP price on it's own.