Hi! I am using J 4.1.5 with VM 4.0.6.
Right now in my chart i have 3 prices: the discounted one, the amount of the discount and the total price.
This is a little weird and i would like to replace the first discounted price with the base price.
For example as you can sei in the attached image i have a discounted price of 200 euros, a discount of 300 and a total price of 200.
Instead I would like to have the base price of 500 euros, a discount of 300 and a total price of 200.
Which is the file I have to change to modify this? I think I just need to change the type of price it uses in the first column replacing the discounted one with the base one.
Thank you!
override & change
components\com_virtuemart\sublayouts\prices.php
Are you sure this is the file that affects the layout of the cart?
I try to editi it but nothing changes...
I have no idea what your template uses but if it's up to date then it should be using this
********** edit *****************
sorry -- just saw you meant the cart - I thought u meant the product price displays
I have found the strings in com_virtuemart/views/cart/tmpl/default_pricelist.php.
This is the code that can be changed
<td class="vm-cart-item-basicprice" >
<?php
if (VmConfig::get ('checkout_show_origprice', 1) && $prow->prices['discountedPriceWithoutTax'] != $prow->prices['priceWithoutTax']) {
echo '<span class="line-through">' . $this->currencyDisplay->createPriceDiv ('basePriceVariant', '', $prow->prices, TRUE, FALSE) . '</span><br />';
}
if ($prow->prices['discountedPriceWithoutTax']) {
echo $this->currencyDisplay->createPriceDiv ('discountedPriceWithoutTax', '', $prow->prices, FALSE, FALSE, 1.0, false, true);
} else {
echo $this->currencyDisplay->createPriceDiv ('basePriceVariant', '', $prow->prices, FALSE, FALSE, 1.0, false, true);
} ?>
</td>
I changd basePriceVariant with basePrice and it seems to work.
Now I have as in the attached image.
I wonder how to change code to have on the third column only the first price with no strike and not also the discounted one.
Someone can help me with code?
Thanks
try just
echo $this->currencyDisplay->createPriceDiv ('basePriceVariant', '', $prow->prices, FALSE, FALSE, 1.0, false, true);
Hello micropalla,
RE: "I am using J 4.1.5 with VM 4.0.6".
Apart from the basePriceVariant / basePrice situation, can you successfully place live orders?
The reason I'm asking is I tried many times with those exact versions but couldn't.
Would love to know if you can as it would reveal that my problem is server set up related (unless you've made some custom tweaks to 4.1.5 / VM 4.0.6 which you'd be willing to share).
Yes, it seems to work even if I have problems sending the email to the buyer.
But probably some mistakes in my configuration.