Exemplo n.º 1
0
 protected function _afterBrowse(KControllerContextInterface $context)
 {
     if ($this->getController()->canPurge()) {
         $this->addPurge();
     }
     return parent::_afterBrowse($context);
 }
Exemplo n.º 2
0
 /**
  * If the method is called with one of the standard Joomla toolbar buttons translate the label correctly
  *
  * @param string $name   The command name
  * @param array  $config The command configuration options
  *
  * @return $this
  */
 public function addCommand($name, $config = array())
 {
     if (!isset($config['label']) && in_array($name, self::$_default_buttons)) {
         $config['label'] = 'JTOOLBAR_' . $name;
     }
     return parent::addCommand($name, $config);
 }