You are here

class views_filters_selective_exposed_form_plugin in Views Hacks 6

Hierarchy

Expanded class hierarchy of views_filters_selective_exposed_form_plugin

1 string reference to 'views_filters_selective_exposed_form_plugin'
views_filters_selective_views_plugins in views_filters_selective/views_filters_selective.views.inc
Implementation of hook_views_plugins()

File

views_filters_selective/views_filters_selective_exposed_form_plugin.inc, line 3

View source
class views_filters_selective_exposed_form_plugin extends views_plugin_exposed_form_basic {
  function summary_title() {
    return t('Selective Exposed Filters');
  }
  function option_definition() {
    $options = parent::option_definition();
    $options['vfs'] = array(
      'default' => array(),
    );
    return $options;
  }
  function options_form(&$form, &$form_state) {
    parent::options_form($form, $form_state);

    // Go through each filter and add the same options we used to add in hook_form_alter()
    foreach ($this->display->handler
      ->get_handlers('filter') as $label => $filter) {
      if (!$filter->options['exposed']) {
        continue;
      }
      $vfs_options[$label] = views_filters_selective_form_views_ui_config_item_form_alter_do($filter, $this->options['vfs'][$label], $this->view, 'edit-exposed-form-options-' . (isset($form['#type']) && $form['#type'] == 'fieldset' ? 'views-filters-selective-' : '') . 'vfs-' . str_replace('_', '-', $label) . '-vfs-selective', TRUE);
    }
    $form['vfs'] = $vfs_options;
  }
  function exposed_form_alter(&$form, &$form_state) {
    parent::exposed_form_alter($form, $form_state);
    views_filters_selective_form_views_exposed_form_alter_do($form, $form_state, $this->options['vfs']);
  }

}

Members

Namesort descending Modifiers Type Description Overrides
views_filters_selective_exposed_form_plugin::exposed_form_alter function Overrides views_plugin_exposed_form::exposed_form_alter
views_filters_selective_exposed_form_plugin::options_form function Provide a form to edit options for this plugin. Overrides views_plugin_exposed_form::options_form
views_filters_selective_exposed_form_plugin::option_definition function Information about options for all kinds of purposes will be held here. Overrides views_plugin_exposed_form::option_definition
views_filters_selective_exposed_form_plugin::summary_title function Return a string to display as the clickable title for the control. Overrides views_plugin_exposed_form_basic::summary_title
views_object::$definition property Handler's definition
views_object::$options property Except for displays, options for the object will be held here. 1
views_object::construct function Views handlers use a special construct function so that we can more easily construct them with variable arguments. 6
views_object::destroy function 2
views_object::export_option function 1
views_object::export_options function
views_object::options function Set default options on this object. Called by the constructor in a complex chain to deal with backward compatibility. 1
views_object::set_default_options function Set default options. For backward compatibility, it sends the options array; this is a feature that will likely disappear at some point.
views_object::set_definition function Let the handler know what its full definition is.
views_object::unpack_options function Unpack options over our existing defaults, drilling down into arrays so that defaults don't get totally blown away.
views_object::unpack_translatable function Unpack a single option definition.
views_object::unpack_translatables function Unpacks each handler to store translatable texts.
views_object::_set_option_defaults function
views_plugin::$display property The current used views display.
views_plugin::$plugin_type property The plugin type of this plugin, for example style or query.
views_plugin::$view property The top object of a view. Overrides views_object::$view 1
views_plugin::additional_theme_functions function Provide a list of additional theme functions for the theme information page
views_plugin::options_submit function Handle any special handling on the validate form. 9
views_plugin::options_validate function Validate the options form. 8
views_plugin::theme_functions function Provide a full list of possible theme templates used by this style.
views_plugin::validate function Validate that the plugin is correct and can be saved. 2
views_plugin_exposed_form::exposed_form_submit function This function is executed when exposed form is submited.
views_plugin_exposed_form::exposed_form_validate function
views_plugin_exposed_form::init function Initialize the plugin.
views_plugin_exposed_form::post_render function
views_plugin_exposed_form::pre_execute function
views_plugin_exposed_form::pre_render function 1
views_plugin_exposed_form::query function Add anything to the query that we might need to. Overrides views_plugin::query 1
views_plugin_exposed_form::render_exposed_form function Render the exposed filter form.
views_plugin_exposed_form::reset_form function Provide a reset form if one was requested.