Your IP : 216.73.216.240
<?php
/**
* @package FFGate
* @author Yves Hoppe <yves@compojoom.com>
* @date 26.11.13
*
* @copyright Copyright (C) 2008 - 2013 compojoom.com - Yves Hoppe. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die('Restricted access');
jimport('joomla.application.component.view');
/**
* Class FFGateViewSites
*
* @since 1.0.0
*/
class FFGateViewSites extends JViewLegacy
{
/**
* Displays the s overview list
*
* @param string $tpl - The template
*
* @return mixed|void
*/
public function display($tpl = null)
{
$this->state = $this->get('state');
$this->items = $this->get('Items');
$this->status = $this->get('status');
$this->pagination = $this->get('Pagination');
$filter_state2 = JFactory::getApplication()->getUserStateFromRequest('com_ffgate.sites.list.' . 'filter_state', 'filter_state', '', 'word');
$this->filter['state'] = JHTML::_('grid.state', $filter_state2, 'JPUBLISHED', 'JUNPUBLISHED');
$this->addToolbar();
parent::display($tpl);
}
/**
* Ads the toolbar buttons
*
* @return void
*/
public function addToolbar()
{
JToolBarHelper::title(JText::sprintf('COM_FFGATE_SITES', 'sites'));
JToolbarHelper::addNew('site.add');
JToolBarHelper::editList('site.edit');
JToolbarHelper::deleteList('site.delete');
JToolbarHelper::publish('site.publish');
JToolbarHelper::unpublish('site.unpublish');
}
}