The reduce option in views_handler_filter_in_operator allows to reduce the options of the filters value form to the default options (user-selected in views admin) only.

For a normal situation (e.g. with views_page) this patch isn't necessary since the filter-form is only build once ($view->render_exposed_form()). When however the form is build twice using the same views object (what I want to do in my project: http://drupal.org/project/viewsforms) it reduces #options twice (second time using the posted input; so it reduces to the selected option only, not to the default options).

It really should use $this->options['value'] (user-selected default options) instead of $this->value (which is during execution rewritten to the posted input).

CommentFileSizeAuthor
options-value-insteadof-value.patch973 bytescasey
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

casey’s picture

Status: Active » Needs review
merlinofchaos’s picture

Status: Needs review » Fixed

Ok, that makes sense. Committed!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.