VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: Lexiboy on July 11, 2014, 08:53:38 AM

Title: modify product selection of mod_virtuemart_product
Post by: Lexiboy on July 11, 2014, 08:53:38 AM
I have a clients that does not use stock control. He only uses the availability field to display the product availability status.

Now he wants to add best sellers to his main page with use of the mod_virtuemart_product. But since he does not use stock control it is possible (and happens) that products that are not currently available are shown as well.

I am trying to find the the source where the products are actually read from the database, but cannot find it.

Where can I adapt the loading of products so that it only loads products that have no value in the availability field?




Title: Re: modify product selection of mod_virtuemart_product
Post by: GJC Web Design on July 11, 2014, 11:04:32 AM
just echo out the $products in the module - and use any node that relates to stock level to filter the results by in the looping

assume there is one there