Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Alphabetize friends/friends-of, group notifications, group owned/member lists #6284

Merged
merged 1 commit into from Dec 23, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 2 additions & 1 deletion engine/lib/access.php
Expand Up @@ -826,7 +826,8 @@ function get_user_access_collections($owner_guid, $site_guid = 0) {

$query = "SELECT * FROM {$CONFIG->dbprefix}access_collections
WHERE owner_guid = {$owner_guid}
AND site_guid = {$site_guid}";
AND site_guid = {$site_guid}
ORDER BY name ASC";

$collections = get_data($query);

Expand Down
3 changes: 3 additions & 0 deletions mod/groups/lib/groups.php
Expand Up @@ -109,9 +109,12 @@ function groups_handle_owned_page() {

elgg_register_title_button();

$dbprefix = elgg_get_config('dbprefix');
$content = elgg_list_entities(array(
'type' => 'group',
'owner_guid' => elgg_get_page_owner_guid(),
'joins' => array("JOIN {$dbprefix}groups_entity ge ON e.guid = ge.guid"),
'order_by' => 'ge.name ASC',
'full_view' => false,
'no_results' => elgg_echo('groups:none'),
));
Expand Down
6 changes: 3 additions & 3 deletions mod/notifications/groups.php
Expand Up @@ -22,13 +22,13 @@
elgg_push_breadcrumb(elgg_echo('settings'), "settings/user/$user->username");
elgg_push_breadcrumb($title);

// Get the form
$people = array();

$dbprefix = elgg_get_config('dbprefix');
$groupmemberships = elgg_get_entities_from_relationship(array(
'relationship' => 'member',
'relationship_guid' => $user->guid,
'type' => 'group',
'joins' => array("JOIN {$dbprefix}groups_entity ge ON e.guid = ge.guid"),
'order_by' => 'ge.name ASC',
'limit' => false,
));

Expand Down
3 changes: 3 additions & 0 deletions pages/friends/index.php
Expand Up @@ -10,11 +10,14 @@

$title = elgg_echo("friends:owned", array($owner->name));

$dbprefix = elgg_get_config('dbprefix');
$options = array(
'relationship' => 'friend',
'relationship_guid' => $owner->getGUID(),
'inverse_relationship' => false,
'type' => 'user',
'joins' => array("JOIN {$dbprefix}users_entity ue ON e.guid = ue.guid"),
'order_by' => 'ue.name ASC',
'full_view' => false,
'no_results' => elgg_echo('friends:none'),
);
Expand Down
3 changes: 3 additions & 0 deletions pages/friends/of.php
Expand Up @@ -10,11 +10,14 @@

$title = elgg_echo("friends:of:owned", array($owner->name));

$dbprefix = elgg_get_config('dbprefix');
$options = array(
'relationship' => 'friend',
'relationship_guid' => $owner->getGUID(),
'inverse_relationship' => true,
'type' => 'user',
'joins' => array("JOIN {$dbprefix}users_entity ue ON e.guid = ue.guid"),
'order_by' => 'ue.name ASC',
'full_view' => false,
'no_results' => elgg_echo('friends:none'),
);
Expand Down