[buddypress-trac] [BuddyPress Trac] #921: bp_group_has_members() - "order" parameter request

buddypress-trac noreply at wordpress.org
Thu Feb 20 19:45:12 UTC 2014


#921: bp_group_has_members() - "order" parameter request
-------------------------------------+------------------
 Reporter:  r-a-y                    |       Owner:
     Type:  enhancement              |      Status:  new
 Priority:  normal                   |   Milestone:  2.0
Component:  Groups                   |     Version:
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-testing  |
-------------------------------------+------------------
Changes (by boonebgorges):

 * keywords:  has-patch needs-testing early-2.0 => has-patch needs-testing
 * milestone:  Future Release => 2.0


Comment:

 Cool, I think we're getting close!

 This patch is getting a bit unwieldy, and really it does two different
 things (and so should be committed separately anyway), so I've split it
 into two patches:

 __921.05.query.diff__

 This contains the modifications to `BP_Group_Member_Query` that allow for
 $type sorting, as well as the mods to the `bp_has_members()` function
 stack that allow you to take advantage of $type. I've made a couple of
 modifications to 04.patch:

 - Changed 'last_modified' and 'first_modified' to 'last_joined' and
 'first_joined'. This makes much more sense from the point of view of
 themers/developers.
 - Changed some of your logic in `set_orderby()`, so that it's possible to
 use *any* of the $type values supported by `BP_User_Query` (even though
 you're only using 'alphabetical' in your patch).
 - Added unit tests for the new $type parameter.
 - Reworked some documentation
 - Removed one instance of setting `$this->query_vars['type']`. This is
 already done in `setup_hooks()`.

 __921.05.template.diff__

 This is the patch that implements the new features in query.diff within
 the context of single groups. I think the only thing I changed here was
 'last_joined' and 'first_joined'. The rest of it looks fine to me.

 Give it a look and see what you think.

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


More information about the buddypress-trac mailing list