VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: Stannite on May 15, 2012, 11:58:22 AM

Title: How not to display stock
Post by: Stannite on May 15, 2012, 11:58:22 AM
Hi All,

When i am seeing productys in a category, i always see the stock for products. When i uncheck the display stock checkbox in the configuration the stock still displays. I tried to set the variable display_stock in the database but it still displays the stock. What can i do to hide the stock for a product?
Title: Re: How not to display stock
Post by: Stannite on May 15, 2012, 12:30:08 PM
I just found it myself,

Make an override for: components\com_virtuemart\views\category\tmpl\default.php
and Change the line: <?php if (!VmConfig::get('use_as_catalog')) {?>
To: <?php if (!VmConfig::get('use_as_catalog') && VmConfig::get('display_stock',1)){?>

This seems to be solved in 2.0.6


greets.