Hello,
i have a problem with the deals extension.
If I choose in the backend a category ID for the extension nothing happens. I see all products with a spezial price in the frontend und deals-grid.
Can i go to the .phtml file and write here a tight category with a little code or somethin else?
Thanks for your help and sorry for my english.
1 answer
Hi Mate,
you can open the file of app\code\local\JoomlArt\JmProductsDeal\Block\list. php there at around line number 97 you would see this snap of code
PHP Code:
$collection = $this->_addProductAttributesAndPrices($collection)
->addStoreFilter()
->addAttributeToFilter('special_from_date', array('date' => true, 'to' => $todayDate))
->addAttributeToFilter('special_to_date', array('or'=> array(
0 => array('date' => true, 'from' => $todayDate),
1 => array('is' => new Zend_Db_Expr('null')))
), 'left')
->addAttributeToSort('special_from_date', 'desc')
->setPageSize($perPage)
->setCurPage(1)
;
Right below it you add this code
PHP Code:
if($this->_config['catsid']){
// get array product_id
$arr_productids = $this->getProductByCategory();
$collection = $collection->addIdFilter($arr_productids);
}
I hope it helps