Exemplo n.º 1
0
 /**
  * Execute and display a template script.
  *
  * @param   string  $tpl  The name of the template file to parse; automatically searches through the template paths.
  *
  * @return  mixed  A string if successful, otherwise a Error object.
  */
 public function display($tpl = null)
 {
     if ($this->showProjectSwitch) {
         $this->projectSwitch = $this->get('ProjectSwitchForm');
     }
     RHelperAsset::load('tracksbackend.css', 'com_tracks');
     return parent::display($tpl);
 }
Exemplo n.º 2
0
 /**
  * Constructor
  *
  * @param   array  $config  A named configuration array for object construction.<br/>
  *                          name: the name (optional) of the view (defaults to the view class name suffix).<br/>
  *                          charset: the character set to use for display<br/>
  *                          escape: the name (optional) of the function to use for escaping strings<br/>
  *                          base_path: the parent path (optional) of the views directory (defaults to the component folder)<br/>
  *                          template_plath: the path (optional) of the layout directory (defaults to base_path + /views/ + view name<br/>
  *                          helper_path: the path (optional) of the helper files (defaults to base_path + /helpers/)<br/>
  *                          layout: the layout (optional) to use to display the view<br/>
  */
 public function __construct($config = array())
 {
     $this->componentTitle .= ' <span class="version">' . DummyHelperSystem::getVersion() . '</span>';
     // If user is Super Admin (or has permission to manage the core component, enables Back2Joomla link)
     if (JFactory::getApplication()->isAdmin()) {
         $this->displayBackToJoomla = true;
     }
     parent::__construct($config);
     $this->sidebarData = array('active' => strtolower($this->_name), 'view' => $this);
 }
Exemplo n.º 3
0
 /**
  * Constructor
  *
  * @param   array  $config  A named configuration array for object construction.<br/>
  *                          name: the name (optional) of the view (defaults to the view class name suffix).<br/>
  *                          charset: the character set to use for display<br/>
  *                          escape: the name (optional) of the function to use for escaping strings<br/>
  *                          base_path: the parent path (optional) of the views directory (defaults to the component folder)<br/>
  *                          template_plath: the path (optional) of the layout directory (defaults to base_path + /views/ + view name<br/>
  *                          helper_path: the path (optional) of the helper files (defaults to base_path + /helpers/)<br/>
  *                          layout: the layout (optional) to use to display the view<br/>
  */
 public function __construct($config = array())
 {
     parent::__construct($config);
     $this->sidebarData = array('active' => strtolower($this->_name));
 }