I'm experiencing a bug with the HS Taxonomy Views filters which I believe may be larger issue with the HS widget. When using a HS taxonomy such as the one below, I experience the following issue. After selecting a term and submitting the form, the view is correctly filtered. However, if I select the "___" (empty) or "<none>" options in the top level of the HS and submit the form again, the form is set back to what I had selected the first time.

Sample options in the HS widget:

___ (empty)
<none>
<all>
Fruits
--> Apple
--> Banana
--> Orange
Vegetables
--> Broccoli
--> Carrot
--> Spinach

Comments

Wim Leers’s picture

Title: HS Views filters do not reset properly » Unable to reset the selection of HS when in a GET form (e.g. Views exposed filter form)
Component: Code - Taxonomy Views » Code
Assigned: Unassigned » Wim Leers
Status: Active » Fixed

Interesting bug. The reason turned out to be an optimization that no longer applies when you're on a GET form. I'm rendering a "flat select" to allow for GET form compatibility. This is rendered on the server after each update, so it only gets set when the server is contacted. But when "none" is selected, the server is not being contacted, because there are no children for it, so an update doesn't make sense. However, when used on a GET form, the server *should* be contacted, so that the "flat select" is re-rendered.

This patch fixes that.

D5: http://drupal.org/cvs?commit=180056
D6: http://drupal.org/cvs?commit=180062

jrbeeman’s picture

This is fantastic - the fix works great. Thanks, Wim.

Status: Fixed » Closed (fixed)

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