/** * Add the page title and toolbar. * * @since 1.6 */ protected function addToolbar() { $canDo = PluginsHelper::getActions(); JToolbarHelper::title(JText::_('COM_PLUGINS_MANAGER_PLUGINS'), 'plugin'); if ($canDo->get('core.edit')) { JToolbarHelper::editList('plugin.edit'); } if ($canDo->get('core.edit.state')) { JToolbarHelper::publish('plugins.publish', 'JTOOLBAR_ENABLE', true); JToolbarHelper::unpublish('plugins.unpublish', 'JTOOLBAR_DISABLE', true); JToolbarHelper::checkin('plugins.checkin'); } if ($canDo->get('core.admin')) { JToolbarHelper::preferences('com_plugins'); } JToolbarHelper::help('JHELP_EXTENSIONS_PLUGIN_MANAGER'); JHtmlSidebar::setAction('index.php?option=com_plugins&view=plugins'); JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_PUBLISHED'), 'filter_enabled', JHtml::_('select.options', PluginsHelper::publishedOptions(), 'value', 'text', $this->state->get('filter.enabled'), true)); JHtmlSidebar::addFilter(JText::_('COM_PLUGINS_OPTION_FOLDER'), 'filter_folder', JHtml::_('select.options', PluginsHelper::folderOptions(), 'value', 'text', $this->state->get('filter.folder'))); JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_ACCESS'), 'filter_access', JHtml::_('select.options', JHtml::_('access.assetgroups'), 'value', 'text', $this->state->get('filter.access'))); $this->sidebar = JHtmlSidebar::render(); }
<option value=""><?php echo JText::_('JOPTION_SELECT_PUBLISHED'); ?> </option> <?php echo JHtml::_('select.options', PluginsHelper::stateOptions(), 'value', 'text', $this->state->get('filter.state'), true); ?> </select> <select name="filter_folder" class="inputbox" onchange="this.form.submit()"> <option value=""><?php echo JText::_('COM_PLUGINS_OPTION_FOLDER'); ?> </option> <?php echo JHtml::_('select.options', PluginsHelper::folderOptions(), 'value', 'text', $this->state->get('filter.folder')); ?> </select> <select name="filter_access" class="inputbox" onchange="this.form.submit()"> <option value=""><?php echo JText::_('JOPTION_SELECT_ACCESS'); ?> </option> <?php echo JHtml::_('select.options', JHtml::_('access.assetgroups'), 'value', 'text', $this->state->get('filter.access')); ?> </select> </div> </fieldset> <div class="clr"> </div>
/** * Method to get the field options. * * @return array The field option objects. * * @since 3.5 */ public function getOptions() { $options = PluginsHelper::folderOptions(); return array_merge(parent::getOptions(), $options); }