public function runFindArticles(framework\Request $request) { $this->articlename = $request['articlename']; if ($this->articlename) { list($this->resultcount, $this->articles) = Article::findArticlesByContentAndProject($this->articlename, framework\Context::getCurrentProject(), 10); } }
public function listen_quicksearchDropdownFoundItems(framework\Event $event) { $searchterm = $event->getSubject(); list($resultcount, $articles) = Article::findArticlesByContentAndProject($searchterm, framework\Context::getCurrentProject()); framework\ActionComponent::includeComponent('publish/quicksearch_dropdown_founditems', array('searchterm' => $searchterm, 'articles' => $articles, 'resultcount' => $resultcount)); }