VirtueMart Forum

VirtueMart 2 + 3 + 4 => Product pricing => Topic started by: 6.522 on April 03, 2020, 22:28:41 PM

Title: show total price without discount (coupon) calculation
Post by: 6.522 on April 03, 2020, 22:28:41 PM
Hello, how can I modify the VM calculations to show (everywhere) order total price without coupon discount. In the VM 2.6 it was quite simple. I've commented out the salesPriceCoupon in the calculationh.php (as below)

//The coupon handling is only necessary if a salesPrice is displayed, otherwise we have a kind of catalogue mode
if($this->_currencyDisplay->_priceConfig['salesPrice']){$this->_cartPrices['billTotal'] = $this->_cartPrices['salesPriceShipment'] + $this->_cartPrices['salesPricePayment'] + $this->_cartPrices['withTax']; //+ $this->_cartPrices['salesPriceCoupon'];


But in VM 3.4 it's more tricky. I'm using AwooCoupon Pro as my only payment method, so discounts are 100% (I don't want to have 0s). Users "buys" products using their account balances (gift certificates).

I have Virtuemart 3.4.2 and Joomla 3.9.6.

Regards
Title: Re: show total price without discount (coupon) calculation
Post by: 6.522 on April 06, 2020, 16:00:38 PM
I guess I could use *2 to multiply 'salesPriceShipment', 'salesPricePayment' and 'withTax' but there are for sure better ways ;)