/** * Displays the view. * */ public function display($tpl = null) { // Get data from model $this->items = $this->get('Items'); $this->state = $this->get('State'); $this->albums = $this->get('Albums'); $this->designs = $this->get('Designs'); if (PFApplicationHelper::getActiveProjectId() <= 0) { $text = JText::_('COM_PROJECTFORK_DESIGNS_WARNING_IMPORT_SELECT_PROJECT'); JFactory::getApplication()->enqueueMessage($text); } // Check for errors if (count($errors = $this->get('Errors'))) { JError::raiseError(500, implode("\n", $errors)); return false; } if ($this->getLayout() !== 'modal') { $this->addToolbar(); if (version_compare(JVERSION, '3', 'ge')) { PFdesignsHelper::addSubmenu('import'); $this->sidebar = JHtmlSidebar::render(); } } parent::display($tpl); }
public function display($cachable = false, $urlparams = false) { if (version_compare(JVERSION, '3', 'lt')) { PFdesignsHelper::addSubmenu(JFactory::getApplication()->input->get('view', $this->default_view)); } parent::display(); return $this; }
/** * Displays the view. * */ public function display($tpl = null) { // Get data from model $this->items = $this->get('Items'); $this->pagination = $this->get('Pagination'); $this->state = $this->get('State'); $this->authors = $this->get('Authors'); $this->nulldate = JFactory::getDbo()->getNullDate(); // Check for errors if (count($errors = $this->get('Errors'))) { JError::raiseError(500, implode("\n", $errors)); return false; } if ($this->getLayout() !== 'modal') { $this->addToolbar(); if (version_compare(JVERSION, '3', 'ge')) { PFdesignsHelper::addSubmenu('albums'); $this->sidebar = JHtmlSidebar::render(); } } parent::display($tpl); }