00001 <?php
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035 class Mage_Adminhtml_Block_System_Store_Store extends Mage_Adminhtml_Block_Widget_Grid_Container
00036 {
00037 public function __construct()
00038 {
00039 $this->_controller = 'system_store';
00040 $this->_headerText = Mage::helper('adminhtml')->__('Manage Stores');
00041 parent::__construct();
00042 }
00043
00044 protected function _prepareLayout()
00045 {
00046
00047 $this->_updateButton('add', 'label', Mage::helper('core')->__('Create Website'));
00048 $this->_updateButton('add', 'onclick', "setLocation('".$this->getUrl('*/*/newWebsite')."')");
00049
00050
00051 $this->_addButton('add_group', array(
00052 'label' => Mage::helper('core')->__('Create Store'),
00053 'onclick' => 'setLocation(\'' . $this->getUrl('*/*/newGroup') .'\')',
00054 'class' => 'add',
00055 ));
00056
00057 /* Add Store button */
00058 $this->_addButton('add_store', array(
00059 'label' => Mage::helper('core')->__('Create Store View'),
00060 'onclick' => 'setLocation(\'' . $this->getUrl('*/*/newStore') .'\')',
00061 'class' => 'add',
00062 ));
00063
00064 return parent::_prepareLayout();
00065 }
00066
00067 public function getAddNewButtonHtml()
00068 {
00069 return join(' ', array(
00070 $this->getChildHtml('add_new_website'),
00071 $this->getChildHtml('add_new_group'),
00072 $this->getChildHtml('add_new_store')
00073 ));
00074 }
00075 }