I use the Hierarchical Select facility to build new groups deep within others and it seems to work perfectly!
HOWEVER, when I try to create a group from within the context of another (via the OG Group details Block) using the link...
node/add/group?og_parent=1780
...it does not appear to set up the parental trail correctly as I would expect.
For example, if I am currently viewing the group node (nid:1780)...
STAFF > ADMIN STAFF > ADMIN DEPARTMENTS > ADMISSIONS
... and I use the above link with the hope of creating a group called 'EXAMS'...
I would expect the parental tree for the newly created group to be reflected in the HS drop-down menus as....
STAFF > ADMIN STAFF > ADMIN DEPARTMENTS > ADMISSIONS > EXAMS
...but the consequently created group does not show the parental tree in the Hierarchical Selection drop-down menus when I go to re-visit the node edit form.
Do I have the wrong expectations here?
Thank you.
Comments
Comment #1
bschilt commentedI can reproduce this. Its definitely a bug.
Comment #2
sirclickalotExcellent, thank you for you quick response.
Your module is a great thing and I think that addressing this is pretty crucial because in all my experience of working with staff in fairly deeply embedded sub departments, they will ALWAYS want to create such groups from within the context that they are current at - they mostly neither know, understand or give a monkey's precisely where they are in the overall hierarchy, that is up to us (as coders) to deal with.
Comment #3
mstef commentedFixed og_subgroups_get_group_parents() to return in order of parent -> grand parents.
It has to be done like that because the recursive will run to the very end, then add as it goes backwards.
You can array_reverse(), if needed.
I didn't fix or commit the needed change to HS, because I'm not sure how you want that done. Can you take care of that?
Comment #4
bschilt commentedThis fix has been committed.