Download & Extend

Multiple choice in an exposed Views filter?

Project:Simple hierarchical select
Version:7.x-1.x-dev
Component:User interface
Category:support request
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

Hi all -

I'm very excited to see this module, and it functions quite nicely. Is there a way to create a Views filter that uses SHS and has multiple widgets? In other words, if I have a hierarchical taxonomy, and a given node might have more than one term from that taxonomy, is there a way to "Add another" filter?

Best -

Comments

#1

Version:7.x-1.5» 7.x-1.x-dev
Status:active» needs work

Hi.
Sorry for responding so late.

Hm, initially I thought "hell no, that won't be possible" but now I'm not so sure about this anymore :) The main problem here is we need something similar to "Add new item" as known from unlimited fields.
Maybe this will not make it into the next version but if its technically possible, it will happen.

#2

I've committed a change to disable "Allow multiple selections" temporarily until I found a solution for this.

#3

Many thanks - I'm pretty green when it comes to Views, but I will also see if I can figure anything out.

Best -

#4

Status:needs work» postponed

Postponed until a solution (or an idea of a solution) is found.

#5

Status:postponed» needs review

Hello,

I needed this functional, so I created a patch for current dev release.
I tested it with differents views and it worked perfect.
So please review and commit it.
Enjoy ;)

AttachmentSize
shs-multiple_choice_in_an_exposed_views_filter-1909140-5.patch 13.64 KB

#6

Status:needs review» needs work

Applied the patch and opened a node saved before: all elements are hidden now. Seems something went wrong while getting the correct data for the elements.
Sorry, patch didn't apply correctly. Needs reroll.

#7

This patch for this dev version http://drupalcode.org/project/shs.git/commit/5a2a874.
Can you give me more information about errors that you get?

#8

The patch simply does not apply (especially the views handlers remain unmodified).

#9

Very strange, I have tested it.
Will you commit any code today?
I will create a new patch for newest dev release.
And it will be very helpfull if you enable automatic tests in you project settings.
Thanks.

#10

Status:needs work» needs review

A new patch.
Just follow this steps:
git am shs-multiple_choice_in_an_exposed_views_filter-1909140-10.patch
git push origin 7.x-1.x
Don't forget to clear cache.
Please review.

AttachmentSize
shs-multiple_choice_in_an_exposed_views_filter-1909140-10.patch 13.6 KB

#11

Status:needs review» fixed

Thanks for the patch, now everything works.
Committed to 7.x-1.x-dev.
The only issue I see here is if you have terms on one level with same name it could be hard to select the right one. But the current solution is better than no solution ;)

Screenshot for reference:
1909140-11.png

AttachmentSize
1909140-11.png 20.29 KB

#12

Status:fixed» closed (fixed)

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

#13

I think the right solution should be single-choice select boxes

nobody click here