/**
  * ACL validation before html generation
  *
  * @return string
  */
 protected function _toHtml()
 {
     if (Mage::getSingleton('admin/session')->isAllowed('system/cache')) {
         return parent::_toHtml();
     }
     return '';
 }
예제 #2
0
 protected function _prepareLayout()
 {
     if ($this->getRewriterStatus()) {
         $this->setChild('change_status_button', $this->getLayout()->createBlock('adminhtml/widget_button')->setData(array('label' => Mage::helper('adminhtml')->__('Disable'), 'onclick' => 'setLocation(\'' . $this->getUrl('*/*/disable') . '\')', 'class' => 'save')));
     } else {
         $this->setChild('change_status_button', $this->getLayout()->createBlock('adminhtml/widget_button')->setData(array('label' => Mage::helper('adminhtml')->__('Enable'), 'onclick' => 'setLocation(\'' . $this->getUrl('*/*/enable') . '\')', 'class' => 'save')));
     }
     $this->setChild('save_button', $this->getLayout()->createBlock('adminhtml/widget_button')->setData(array('label' => Mage::helper('adminhtml')->__('Save changes'), 'onclick' => '$(\'rewritesForm\').submit()', 'class' => 'save')));
     $this->setChild('reset_button', $this->getLayout()->createBlock('adminhtml/widget_button')->setData(array('label' => Mage::helper('aitsys')->__('Reset rewrites order to default values'), 'onclick' => 'if (confirm(\'' . Mage::helper('aitsys')->__('Are you sure want to reset rewrites order?') . '\')) $(\'rewritesResetForm\').submit()', 'class' => 'cancel')));
     return parent::_prepareLayout();
 }
예제 #3
0
파일: List.php 프로젝트: rajarshc/Rooja
 protected function _prepareLayout()
 {
     $this->setChild('save_button', $this->getLayout()->createBlock('adminhtml/widget_button')->setData(array('label' => Mage::helper('adminhtml')->__('Save changes'), 'onclick' => '$(\'rewritesForm\').submit()', 'class' => 'save')));
     $this->setChild('reset_button', $this->getLayout()->createBlock('adminhtml/widget_button')->setData(array('label' => $this->_aithelper()->__('Reset rewrites order to default values'), 'onclick' => 'if (confirm(\'' . $this->_aithelper()->__('Are you sure want to reset rewrites order?') . '\')) $(\'rewritesResetForm\').submit()', 'class' => 'cancel')));
     return parent::_prepareLayout();
 }
예제 #4
0
 public function __construct()
 {
     parent::__construct();
     $this->setTemplate('aitsys/notification.phtml');
 }
예제 #5
0
 protected function _prepareLayout()
 {
     return parent::_prepareLayout();
 }
예제 #6
0
파일: One.php 프로젝트: CherylMuniz/fashion
 protected function _construct()
 {
     parent::_construct();
     $this->setTemplate('aitsys/patch/instruction/one.phtml');
 }