VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: evin63 on May 23, 2013, 11:59:21 AM

Title: VM as catalogue show products stock
Post by: evin63 on May 23, 2013, 11:59:21 AM
Hi, I'm using joomla 2.5.11 and VM 2.0.20b
I use VM as catalogue  mode, and my problem is that I want to display the products quantity stock (in product details page)
Now I can see only the price and "ask a question"
Is there a way to display also stock?

I think I have to modify default.php
in mytemplate/html/com_virtuemart/productdetails/default.php

I found about in line 240 this code
<?php // Add To Cart Button
if (!VmConfig::get('use_as_catalog', 0)  ecc...

that I think remove all the cart but also stock.

but I'm not able to modify it to remove cart, but not the stock.

Can anyone please help me?

Thanks
Regards

Title: Re: VM as catalogue show products stock
Post by: jenkinhill on May 23, 2013, 16:41:09 PM
Use <?php echo $this->product->product_in_stock ?>    See http://forum.virtuemart.net/index.php?topic=92756.0

Make sure you make overrides from your modified template files.
Title: Re: VM as catalogue show products stock
Post by: evin63 on May 23, 2013, 19:37:05 PM
Thank you very much!
Your answer to my question was really helpful for me!
Best Regards