コード例 #1
0
 public function getPosts()
 {
     $collection = parent::_prepareCollection();
     $tag = $this->getRequest()->getParam('tag');
     if ($tag) {
         $collection->addTagFilter(urldecode($tag));
     }
     parent::_processCollection($collection);
     return $collection;
 }
コード例 #2
0
ファイル: Cat.php プロジェクト: velozmontero/tango-mango-page
 public function getPosts()
 {
     $category = $this->getCategory();
     if (!$category->getCatId()) {
         return false;
     }
     $collection = parent::_prepareCollection()->addCatFilter($category->getCatId());
     parent::_processCollection($collection, $category);
     return $collection;
 }