/** * Display the Feedbacks view * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return void */ function display($tpl = null) { // Get application $app = JFactory::getApplication(); $context = "feedback.list.admin.feedback"; // Get data from the model $this->items = $this->get('Items'); $this->pagination = $this->get('Pagination'); $this->state = $this->get('State'); $this->filterForm = $this->get('FilterForm'); $this->activeFilters = $this->get('ActiveFilters'); // What Access Permissions does this user have? What can (s)he do? $this->canDo = FeedbackHelper::getActions(); // Check for errors. if (count($errors = $this->get('Errors'))) { JError::raiseError(500, implode('<br />', $errors)); return false; } // Set the toolbar and number of found items $this->addToolBar(); // Display the template parent::display($tpl); // Set the document $this->setDocument(); }
/** * Display the Feedback view * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return void */ public function display($tpl = null) { // Get the Data $this->form = $this->get('Form'); $this->item = $this->get('Item'); $this->script = $this->get('Script'); // What Access Permissions does this user have? What can (s)he do? $this->canDo = FeedbackHelper::getActions($this->item->id); // Check for errors. if (count($errors = $this->get('Errors'))) { JError::raiseError(500, implode('<br />', $errors)); return false; } // Set the toolbar $this->addToolBar(); // Display the template parent::display($tpl); // Set the document $this->setDocument(); }