Example #1
0
 /**
  * This method is called before rendering HTML
  *
  * @return Mage_Backend_Block_Widget_Form|Mage_Core_Block_Abstract
  */
 protected function _beforeToHtml()
 {
     $this->_prepareForm();
     $this->_initFormValues();
     return parent::_beforeToHtml();
 }
Example #2
0
 protected function _beforeToHtml()
 {
     if ($activeTab = $this->getRequest()->getParam('active_tab')) {
         $this->setActiveTab($activeTab);
     } elseif ($activeTabId = Mage::getSingleton('Mage_Backend_Model_Auth_Session')->getActiveTabId()) {
         $this->_setActiveTab($activeTabId);
     }
     $_new = array();
     foreach ($this->_tabs as $key => $tab) {
         foreach ($this->_tabs as $k => $t) {
             if ($t->getAfter() == $key) {
                 $_new[$key] = $tab;
                 $_new[$k] = $t;
             } else {
                 if (!$tab->getAfter() || !in_array($tab->getAfter(), array_keys($this->_tabs))) {
                     $_new[$key] = $tab;
                 }
             }
         }
     }
     $this->_tabs = $_new;
     unset($_new);
     $this->assign('tabs', $this->_tabs);
     return parent::_beforeToHtml();
 }
Example #3
0
 protected function _beforeToHtml()
 {
     $this->_prepareGrid();
     return parent::_beforeToHtml();
 }