public function beforeRender() { // set the same layout for all modules so they look the same like // other pages in administration $this->setLayout('../../../../../AdminModule/templates/@layout'); parent::beforeRender(); }
public function beforeRender() { parent::beforeRender(); $this->template->picturecount = $this->pictures->countBy(); $this->template->tagcount = $this->tags->countBy(); $this->template->usercount = $this->users->countBy(); if (!$this->user->isAllowed('Admin:Admin', Authorizator::CREATE)) { $this->flashMessage('Nacházíte se v **demo** ukázce administrace. Máte právo prohlížet, nikoliv však editovat...', 'info'); } }
public function beforeRender() { parent::beforeRender(); $this->template->setTranslator($this->translator); $this->template->menuPresenters = $this->menuModules; $this->template->languages = $this->languages->getAll(); $this->template->webLanguage = $this->webLanguage; }