Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I have a global filter block filtering on a taxonomy reference field, with the 'Multi choice check boxes' widget, and 'Invoke widget immediately upon select' enabled.
The filter block shows up as expected, but the 'All' option doesn't seem to work. I expected 'All' to clear the current selection, but that doesn't happen. Selecting 'All' does trigger a POST request, but the only effect is that 'All' comes back unselected and nothing changed.
Is this a bug, or did I do something wrong in the configuration?
Comments
Comment #1
RdeBoerHi Marc,
It's kind of a bug.
'All', 'Invoke immediately' and 'Mutli choice check boxes' don't go together very well. Not out-of-the-box anyway.
I believe there's a warning on the block configuration page that discourages the use of 'All' in this combination.
This may have to be fixed with additional javascript.
Any takers?
Rik
Comment #2
marcvangendThanks for the reply, Rik. I did see the notice about 'Invoke immediately', but turning that off didn't change anything. I did not see a warning about the combination of 'All' and 'Multi choice check boxes'.
Anyway, I'll see if I can use my (limited) js/jQuery knowledge to find out how to fix this.
Comment #3
jlcerrada CreditAttribution: jlcerrada commentedI had the same problem with the 'multi choice check' and I solved it with the following js code.
Comment #4
ybabel CreditAttribution: ybabel as a volunteer commentedMy solution in templates/block--global-filter.tpl.php :
works with standard drupal jQuery