Hi - great module, especially the interaction with organic groups.

I made a simple change to line 458 (function userplus_admin_usergroups) that might be considered for future releases. It simply makes sure the organic group is active:

  $result = db_query('SELECT ug.nid, n.title 
                      FROM {og} ug
                      INNER JOIN {node} n
                      ON ug.nid = n.nid 
	                   *** WHERE n.status = 1 ***
                      ORDER BY n.title');

I also had to manually unset a few roles that I didn't want to be assignable (function userplus_admin_userperms)... might be nice to add a small form to the settings page where admins can exclude specific roles / groups.

Comments

marcp’s picture

Both are good ideas.

It might be nice to see all the pending subscriptions in all groups -- without your patch, active and inactive users in a group show up the same when assigning groups -- they both appear to be members of the group. With your patch, inactive (pending) users show up as unsubscribed. I'd like to have a better way of showing that they are in the group but not yet subscribed.

Hmm.

marcp’s picture

Title: n.status = active; exclude roles » Allow filtering of groups
Version: 5.x-1.0 » 6.x-2.x-dev

I changed the title to reflect the feature request. You can now configure which roles appear on the add users form and the role assignment form -- see #373511: Exclude some roles for more information.