Fix nette 3.0
This commit is contained in:
@@ -21,26 +21,6 @@ use App\Model\Database\Facade\TermFacade;
|
||||
final class HomePresenter extends BaseFrontPresenter
|
||||
{
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @return AlesWita\Components\VisualPaginator
|
||||
*/
|
||||
protected function createComponentPaginator(): VisualPaginator
|
||||
{
|
||||
$paginator = $this->visualPaginatorFactory->create();
|
||||
|
||||
$paginator->ajax = false;
|
||||
$paginator->canSetItemsPerPage = true;
|
||||
$paginator->setItemsPerPage(100);
|
||||
|
||||
//$paginator->templateFile = __DIR__ . '/my_awesome_template.latte';
|
||||
|
||||
return $paginator;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public function searchFormSucceededIpa(UI\Form $form, $values)
|
||||
{
|
||||
$translation = $values->translation;
|
||||
@@ -96,7 +76,6 @@ final class HomePresenter extends BaseFrontPresenter
|
||||
} else {
|
||||
|
||||
$id = $this['searchForm']['translation']->value;
|
||||
dump($id);
|
||||
if (isset($this->translations[$id])) {
|
||||
$t = $this->translations[$id];
|
||||
$this->redirect('Front:Home:select', $t["slug"], $this['searchForm']['string']->value);
|
||||
@@ -120,15 +99,7 @@ final class HomePresenter extends BaseFrontPresenter
|
||||
|
||||
public function actionIpa()
|
||||
{
|
||||
if ($this->getRequest()->isMethod('GET')) {
|
||||
if ($this->term) {
|
||||
$this['searchForm']['string']->setValue($this->term);
|
||||
$result = $this->doSearch('TermsFullQuery', $this->slugs[$this->slug]->id, $this->term);
|
||||
if ($result) $this->template->result = $result;
|
||||
}
|
||||
}
|
||||
|
||||
$this['searchForm']->onSuccess[] = array($this, 'searchFormSucceededIpa');
|
||||
$this->redirect('Search:ipa',$this->translation,$this->term);
|
||||
}
|
||||
|
||||
public function actionInteractive()
|
||||
|
||||
Reference in New Issue
Block a user