Error in vmModel Product with list of products for the module in the "Latest". There is a big load on MSQL server and incorrectly showing the last products
you must add the file product.php $orderBy = 'ORDER BY p.`virtuemart_product_id'; in case 'latest':
if($group){
$groupBy = 'group by p.`virtuemart_product_id`';
switch ($group) {
case 'featured':
$where[] = 'p.`product_special`="1" ';
$orderBy = 'ORDER BY RAND()';
break;
case 'latest':
$date = JFactory::getDate( time()-(60*60*24*7) );
$dateSql = $date->toMySQL();
$where[] = 'p.`modified_on` > "'.$dateSql.'" ';
$this->filter_order_Dir = 'DESC';
$orderBy = ' ORDER BY p.`virtuemart_product_id`'; // <<<-------------------- ADD THIS CODE
break;
case 'random':
$orderBy = ' ORDER BY RAND() ';
break;
case 'topten';
$orderBy = ' ORDER BY product_sales ';
$this->filter_order_Dir = 'DESC';
}
$joinPrice = true ;
$this->searchplugin = false ;
}
}
or orderBy p modified on, or?
there is a selection a WHERE
? anyway checkout the svn.