groups in controller of single page
Permalink
Hi,
Im trying to do the following:
I have my users in hierarchy groups
Group1
- Group 2
- Group 3
- Group 4
- Group 5
i would like to do the following:
on a single page i can programmatically add users to one of the below Group 2 (so either 3, 4, 5)
If i add a user that is part of Group 3 and i add him to Group 4 i would like for him to automatically be removed from the other groups below Group 2. the tricky part is that i do not know how many groups there are going to be below group 2. So does anyone know how i can get this to work in the controller of the single page
what i have working:
i have single page where i can add the users to a one of the groups, but i cant seem to remove the user from the groups where the parent group is Group2.
so basically if i look up the user is see in his groups
Group 2
Group 2/Group 3
Group 2/Group 4
and it should be
Group 2
Group 2/Group 4
i hope i made my issue somewhat clear and would like to hear if someone has a good idea on how to detect the groups below a parent group and work from there
Im trying to do the following:
I have my users in hierarchy groups
Group1
- Group 2
- Group 3
- Group 4
- Group 5
i would like to do the following:
on a single page i can programmatically add users to one of the below Group 2 (so either 3, 4, 5)
If i add a user that is part of Group 3 and i add him to Group 4 i would like for him to automatically be removed from the other groups below Group 2. the tricky part is that i do not know how many groups there are going to be below group 2. So does anyone know how i can get this to work in the controller of the single page
what i have working:
i have single page where i can add the users to a one of the groups, but i cant seem to remove the user from the groups where the parent group is Group2.
so basically if i look up the user is see in his groups
Group 2
Group 2/Group 3
Group 2/Group 4
and it should be
Group 2
Group 2/Group 4
i hope i made my issue somewhat clear and would like to hear if someone has a good idea on how to detect the groups below a parent group and work from there