True multiple select support
mouse77e - November 13, 2007 - 14:05
| Project: | Hierarchical Select |
| Version: | 5.x-1.x-dev |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Wim Leers |
| Status: | closed |
Description
I am tempted to use your excellent module for my site but I have a challenge, Multiple Selections.
I am looking to use the module to allow people to select an exact location e.g.
City >> Suburb >> Street >> Restaurant
but each member may like to select multiple restaurants.
Would it be better in your opinion to have multiple sets of the same selection boxes or can the module be modified to allow multiple selections?

#1
2 possible solutions:
1) use multiple content_taxonomy fields, this may not be really what you want
2) sponsor me to write a better way for doing this: http://drupal.org/node/176936#comment-606565 (see the attached image)
#2
If dear Wim, i could afford to sponsor you i would but alas i am doing this on a shoestring! but that image does look just like what i would like!
what i am aiming at is to use this in my site http://afterthemouse.com to record work locations. some people worked in one place some in 20 places. i have listed most of them (thats arround 2000 locations possible) but i want to make it as easy as possible to edit profiles, both to add and delete locations.
#3
I'm afraid you'll have to wait until somebody sponsors it or until I have time and finished higher priority work.
#4
Just putting myself on the waiting list...
Michelle
#5
Just out of interest what level of sponsorship might you be looking for?
#6
Please contact me via my contact tab here at Drupal.org or via http://wimleers.com/contact.
#7
The initial version with multiple select support has been committed: http://drupal.org/cvs?commit=93142. The "Remove" button does not yet work though, that's for the next revision.
#8
Thanks very much for doing this. The demo looked awesome. I can't wait to try it out!
Michelle
#9
And now it is complete.
People who are interested in this new feature, please start testing it and file bug reports! (I hope there won't be too many, of course.)
#10
If $dropbox->lineages is not set i get errors on line 532, 537, 333
is wrapping it in
if ($dropbox->lineages) { ... }a solution?#11
I had some thoughts on layout. the width of 10% lets lines wrap too early for longer lineages and the add button is one line below the hierarchical select, is this on purpose?
What about this in the css file?
div.hierarchical-select-dropbox {
width: 70%;
}
input.hierarchical-select-add-to-dropbox {
margin-top:0;
}
AND
.hide() in hierarchical_select.js line 92 is commented ;)
#12
Sorry, tell me if this is not my responsibility. Setting it to active.
#13
70% is super ugly, because then there will be too much whitespace. Feel free to improve the CSS, I agree that it could be improved *a lot*, but I'm no CSS wizard... Please continue CSS improvements in another issue.
I'm working on the bug you've reported.
#14
Fixed now.
The changes you suggested wouldn't have been sufficient. Check the diff from version 1.12 to version 1.14 of the .module file if you want to know what had to be changed.
And please report bugs as new issues the next time, that's exactly what the issue tracker is for!
#15
Automatically closed -- issue fixed for two weeks with no activity.