Recent Topics

1 Apr 05, 2006 17:27    

Hi. Thank you for b2evo. This is not a request, but a consultation.

I'm thinking about implementing M:N group:user relationships in b2evolution-1.6-2005-11-25. Then b2evo and LDAP authentication could benefit from LDAP groups. I'd like to contribute that back to b2evo.

I see that 1.6 and 1.7 have different directory structure, and that it became MVC. I didn't install b2evo 1.7, but from http://doc.b2evolution.net/DB_schema/b2evo_1_7.png I understand that there's still just N:1 user:group relationship, i.e. any user has exactly one group. Am I right?

I've checked 1.6 code. It looks to me that M:N groups would involve:
- new DB table which would hold M:N associations, something like 'T_coll_user_groups' = > $tableprefix.'users_groups'
- replacement of "->Group" and " setGroup"
- replacement of admin UI
---- when setting user's groups, use multiselect list
---- requirement: user would have at least one group

Now, can you see any obstacles? The only real ones I can think of:
- too much code to change in one go - I guess setGroup() could be modified in the interim to *add* user to given group. That would allow existing installation scripts etc work.
- customized/3rd party plugins - we could leave $User->Group as a reference to the first of groups the user is in
- and then i18messages for admin UI - I guess the community would take care of that.

I have a surceforge account. Do you use separate CVS branches for different "generations" (1.6 vs 1.7)? How do you developers communicate, approve etc?

2 Apr 05, 2006 17:56

I don't follow all that you're saying but you can test the latest CVS version (1.8) at http://demo.b2evolution.net/. You can add users/groups and assign them to each other. Just login to the backoffice and have at it. :D

3 Apr 05, 2006 17:59

Nate, he's saying that one user can't be in two groups. That could be useful for some people. It's not part of the CVS code right now.

4 Apr 05, 2006 21:32

Peter, you're right: there's still a 1:1 relationship.

It's on the todo list already:
http://dev.b2evolution.net/todo.php?title=multiple_groups_per_user&more=1&c=1&tb=1&pb=1

You should ask François to add you to the "Developers" group at the todo blog and also as a Dev on the SF.net project.

Already before that, you might want to add your thoughts to the entry (as visitor).

From what I know, your layout (and required changes) make sense. Additionally, the check_perm method for the User object needs to be changed probably, to loop through all his groups when checking for perms.

We've used to have a mailing list, but that was closed some days ago and the new one isn't up yet: the "todo blog" is the way to go.

We currently only have a "v-0-9" branch and the development takes place in HEAD. I really hope, that we make the switch from CVS to SVN soon, as it will allow far easier branching, which makes a lot of sense for a feature like this.

I'd really like to see this feature get added, because it allows a lot more flexibility regarding perms and will help you with it, if there's a need.. :)

Thank you.

5 Apr 09, 2008 00:05

Hello,

The b2evo support community is sure a friendly bunch. Great work on a quality product. I'm currently running 1.10.2.

So, is there any new info on this Subject? Everything I found came to a halt two years ago. I hope I'm just missing some new info. as this would be a very useful feature to allow users to exist in multiple groups.

I also found a TODO list entry at: http://todo.b2evolution.net/todo.php/2005/12/30/multiple_groups_per_user

Thanks for any assistance
Brian


Form is loading...