public static function GroupMembership::getByStatus in Group 7
Get all memberships by status for a user.
Parameters
int $uid: The uid of the user to retrieve memberships for.
string $status: The machine name of the membership status.
Return value
array An array of GroupMembership objects.
2 calls to GroupMembership::getByStatus()
- ginvite_init in modules/
ginvite/ ginvite.module - Implements hook_init().
- ginvite_user_page in modules/
ginvite/ pages/ ginvite.inc - Generate the group invite page for a given user.
File
- classes/
group_membership.inc, line 224 - Defines the Entity API class for group memberships.
Class
- GroupMembership
- Main class for group memberships.
Code
public static function getByStatus($uid, $status) {
return group_memberships(array(
'uid' => $uid,
'status' => $status,
));
}