diff --git a/admin-dev/tabs/AdminTabs.php b/admin-dev/tabs/AdminTabs.php deleted file mode 100644 index ff2079abd..000000000 --- a/admin-dev/tabs/AdminTabs.php +++ /dev/null @@ -1,180 +0,0 @@ - -* @copyright 2007-2011 PrestaShop SA -* @version Release: $Revision: 6844 $ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -class AdminTabs extends AdminTab -{ - public function __construct() - { - $this->context = Context::getContext(); - $this->table = 'tab'; - $this->className = 'Tab'; - $this->lang = true; - $this->edit = true; - $this->delete = true; - $this->_select = '(SELECT stl.`name` FROM `'._DB_PREFIX_.'tab_lang` stl WHERE stl.`id_tab` = a.`id_parent` AND stl.`id_lang` = '.(int)$this->context->language->id.' LIMIT 1) AS parent'; - - $this->fieldImageSettings = array('name' => 'icon', 'dir' => 't'); - $this->imageType = 'gif'; - - $tabs = array(0 => $this->l('Home')); - foreach (Tab::getTabs($this->context->language->id, 0) AS $tab) - $tabs[$tab['id_tab']] = $tab['name']; - $this->fieldsDisplay = array( - 'id_tab' => array('title' => $this->l('ID'), 'align' => 'center', 'width' => 25), - 'name' => array('title' => $this->l('Name'), 'width' => 200), - 'logo' => array('title' => $this->l('Icon'), 'align' => 'center', 'image' => 't', 'image_id' => 'class_name', 'orderby' => false, 'search' => false), - 'parent' => array('title' => $this->l('Parent'), 'width' => 200, 'type' => 'select', 'select' => $tabs, 'filter_key' => 'a!id_parent'), - 'module' => array('title' => $this->l('Module'))); - - parent::__construct(); - } - - public function postProcess() - { - /* PrestaShop demo mode */ - if (_PS_MODE_DEMO_) - { - $this->_errors[] = Tools::displayError('This functionnality has been disabled.'); - return; - } - /* PrestaShop demo mode*/ - - if (($id_tab = (int)(Tools::getValue('id_tab'))) AND ($direction = Tools::getValue('move')) AND Validate::isLoadedObject($tab = new Tab($id_tab))) - { - if ($tab->move($direction)) - Tools::redirectAdmin(self::$currentIndex.'&token='.$this->token); - } - else - { - if (!Tools::getValue('position')) - $_POST['position'] = Tab::getNbTabs(Tools::getValue('id_parent')); - parent::postProcess(); - } - } - - private function _posTabs($name, $arrayTabs) - { - if (sizeof($arrayTabs) > 1) - { - echo ' -