[buddypress-trac] [BuddyPress Trac] #3961: Hierarchical groups

buddypress-trac noreply at wordpress.org
Tue Aug 2 21:47:10 UTC 2016


#3961: Hierarchical groups
------------------------------------------------+-----------------------
 Reporter:  sooskriszta                         |       Owner:  dcavins
     Type:  enhancement                         |      Status:  assigned
 Priority:  normal                              |   Milestone:  2.7
Component:  Groups                              |     Version:
 Severity:  normal                              |  Resolution:
 Keywords:  dev-feedback 2nd-opinion has-patch  |
------------------------------------------------+-----------------------
Changes (by dcavins):

 * keywords:  dev-feedback 2nd-opinion => dev-feedback 2nd-opinion has-patch


Comment:

 I'm uploading a new patch that incorporates much of the helpful feedback
 provided here.

 * Make sure the "parent" select is showing all possible groups by
 disabling pagination in the `groups_get_groups()` call.
 * Fixed accessibility problems with form elements.
 * Only show the "subgroups" tab if subgroups exist for that group. (This
 is a change from BPGH's behavior, but since I'm not proposing an override
 to the global `bp_restrict_group_creation()` for subgroups, it probably
 makes sense to always access the group creation screens from the same
 place.)
 * Changed language to "Subgroups". End users can change it to whatever
 with a language file, of course. ;)
 * Added hierarchy breadcrumbs to groups in the groups directory as the
 smallest possible change to the directory that shows hierarchical
 relationships. (Will attach image)
 * Take the setting `bp_restrict_group_creation()` into account when
 calculating who can create subgroups.
 * Add the parent setting to the settings screen for existing and in-
 creation groups.
 * Don't show impossible options on the "who can create subgroups" setting
 if group creation is globally restricted.

 I was thinking of building a walker to display the groups hierarchically
 like threaded comments, but there are some technical hurdles that lead me
 to think that you couldn't use `bp_has_groups()` to fetch the groups in
 the common way, and I'm concerned that people who've gotten used to
 working with that loop would be in for a surprise. I think we'd have to
 fetch all the groups and let the walker work it out. We'd also have to
 base pagination on the number of top-level groups for the current
 directory (groups with a `parent_id` of 0 for the main directory and with
 the `parent_id` of the current group for a subgroup directory). These
 things are doable but a major departure. If we wish to go this route, I
 think we should add a new template `group-tree.php` or similar because it
 will work very differently. (I'm happy to work on this, but I don't want
 to go down a path that we think is a bad idea.)

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/3961#comment:31>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list