Hi
I'm working with category layout right now. I was trying to use the default view, but such functionality is not implemented there at all
Also this will be a very specific modification, becauase Your discount is not global but attached to a product variant (whatever this means, I'm not VM expert).
I'm working with file /html/com_virtuemart/category/default.php lines around 250:
- Code: Select all
if ($this->show_prices == '1') {
if ($product->prices['salesPrice']<=0 and VmConfig::get ('askprice', 1) and !$product->images[0]->file_is_downloadable) {
echo JText::_ ('COM_VIRTUEMART_PRODUCT_ASKPRICE');
}
echo $this->currency->createPriceDiv('basePriceWithTax', '', $product->prices);
echo $this->currency->createPriceDiv('taxAmount','TPL_GK_LANG_VM_INC_TAX', $product->prices);
} ?>
I've been trying hard, but it's just configured in a wrong way. The discount is set as tax, so I have no way to use it in code. So first You need to attach a discount properly, unfortunately I do not know how to do that, You need to ask VM support for that.
Right now, Your discount is hidden in an array:
- Code: Select all
["Tax"]=>
array(1) {
[5]=>
array(8) {
[0]=>
string(13) "descuento 50%"
[1]=>
string(7) "50.0000"
[2]=>
string(2) "-%"
so it's not usable in a way we need it.