From d42771b8a74e665d33d29e7ce3b1612890a596f2 Mon Sep 17 00:00:00 2001 From: ewinslow Date: Tue, 22 Feb 2011 09:09:24 +0000 Subject: Touch ups of groups plugin git-svn-id: http://code.elgg.org/elgg/trunk@8426 36083f99-b078-4883-b0ff-0f9b5a30f544 --- mod/groups/lib/groups.php | 2 +- mod/groups/views/default/forms/groups/delete.php | 4 +-- mod/groups/views/default/forms/groups/invite.php | 35 ++++++++-------------- mod/groups/views/default/forms/groups/search.php | 2 +- mod/groups/views/default/groups/css.php | 8 ++--- .../views/default/groups/group_sort_menu.php | 8 ++--- .../views/default/groups/invitationrequests.php | 10 +++---- .../views/default/groups/membershiprequests.php | 6 ++-- .../default/groups/profile/activity_module.php | 10 ++++++- .../views/default/groups/profile/buttons.php | 4 ++- .../views/default/groups/profile/profile_block.php | 6 ++-- .../views/default/groups/profile/widgets.php | 2 +- .../views/default/groups/sidebar/members.php | 2 +- 13 files changed, 50 insertions(+), 49 deletions(-) (limited to 'mod/groups') diff --git a/mod/groups/lib/groups.php b/mod/groups/lib/groups.php index 8faba3179..a6f262c09 100644 --- a/mod/groups/lib/groups.php +++ b/mod/groups/lib/groups.php @@ -302,7 +302,7 @@ function groups_handle_invite_page($guid) { $title = elgg_echo('groups:invite'); if ($group && $group->canEdit()) { - $content = elgg_view('forms/groups/invite', array('entity' => $group)); + $content = elgg_view_form('groups/invite', array('id' => 'invite_to_group', 'class' => 'mtm', array('entity' => $group))); } else { $content .= elgg_echo('groups:noaccess'); } diff --git a/mod/groups/views/default/forms/groups/delete.php b/mod/groups/views/default/forms/groups/delete.php index 4c380718a..85379a342 100644 --- a/mod/groups/views/default/forms/groups/delete.php +++ b/mod/groups/views/default/forms/groups/delete.php @@ -11,7 +11,7 @@ echo elgg_view('input/hidden', array( )); echo elgg_view('input/submit', array( - 'class' => "elgg-button-cancel", + 'class' => "elgg-button elgg-button-delete", 'value' => elgg_echo('groups:delete'), - 'onclick' => "javascript:return confirm('$warning')", + 'onclick' => "return confirm('$warning');", )); diff --git a/mod/groups/views/default/forms/groups/invite.php b/mod/groups/views/default/forms/groups/invite.php index 73eadb024..d3bcfe580 100644 --- a/mod/groups/views/default/forms/groups/invite.php +++ b/mod/groups/views/default/forms/groups/invite.php @@ -1,29 +1,20 @@ owner_guid); - $forward_url = $group->getURL(); - $friends = elgg_get_logged_in_user_entity()->getFriends('', 0); +$group = $vars['entity']; +$owner = get_entity($vars['entity']->owner_guid); +$forward_url = $group->getURL(); +$friends = elgg_get_logged_in_user_entity()->getFriends('', 0); if ($friends) { -?> -
- - $friends, 'name' => 'user_guid', 'highlight' => 'all')); -?> - - - -
- $friends, 'name' => 'user_guid', 'highlight' => 'all')); + echo elgg_view('input/hidden', array('name' => 'forward_url', 'value' => $forward_url)); + echo elgg_view('input/hidden', array('name' => 'group_guid', 'value' => $group->guid)); + echo elgg_view('input/submit', array('value' => elgg_echo('invite'))); } else { echo elgg_echo('groups:nofriendsatall'); } \ No newline at end of file diff --git a/mod/groups/views/default/forms/groups/search.php b/mod/groups/views/default/forms/groups/search.php index 8912b245c..058a1c11c 100644 --- a/mod/groups/views/default/forms/groups/search.php +++ b/mod/groups/views/default/forms/groups/search.php @@ -4,7 +4,7 @@ $tag_string = elgg_echo('groups:search:tags'); $params = array( 'name' => 'tag', - 'class' => 'search-input', + 'class' => 'elgg-input-search', 'value' => $tag_string, 'onclick' => "if (this.value=='$tag_string') { this.value='' }", ); diff --git a/mod/groups/views/default/groups/css.php b/mod/groups/views/default/groups/css.php index 93e15337f..5276e2bfa 100644 --- a/mod/groups/views/default/groups/css.php +++ b/mod/groups/views/default/groups/css.php @@ -46,10 +46,10 @@ padding-bottom:40px; border-bottom:1px solid #CCCCCC; } -.entity-listing.topic .topic_post p { +.elgg-image-block.topic .topic_post p { margin:10px 0 5px 0; } -.entity-listing.topic:hover { +.elgg-image-block.topic:hover { background-color: white; } @@ -160,8 +160,8 @@ padding:0; } -/* override default entity-listing-info width */ -.group_tool_widget .entity-listing-info { +/* override default elgg-body width */ +.group_tool_widget .elgg-body { width:315px; } .group_widget_link { diff --git a/mod/groups/views/default/groups/group_sort_menu.php b/mod/groups/views/default/groups/group_sort_menu.php index 78a9e72cd..6ba56628e 100644 --- a/mod/groups/views/default/groups/group_sort_menu.php +++ b/mod/groups/views/default/groups/group_sort_menu.php @@ -6,12 +6,12 @@ $group_count = (int)elgg_get_entities(array('types' => 'group', 'count' => true)); $selected = elgg_extract('selected', $vars); - - //url - $url = elgg_get_site_url() . "pg/groups/all/"; + + //url + $url = elgg_get_site_url() . "pg/groups/all/"; ?> -
+
  • >
  • diff --git a/mod/groups/views/default/groups/invitationrequests.php b/mod/groups/views/default/groups/invitationrequests.php index b6dcdfc22..77dabaac2 100644 --- a/mod/groups/views/default/groups/invitationrequests.php +++ b/mod/groups/views/default/groups/invitationrequests.php @@ -6,9 +6,9 @@ if (!empty($vars['invitations']) && is_array($vars['invitations'])) { if ($group instanceof ElggGroup) { ?> -
    +
    "; + echo "
    "; echo elgg_view("profile/icon", array( 'entity' => $group, 'size' => 'tiny', @@ -17,8 +17,8 @@ if (!empty($vars['invitations']) && is_array($vars['invitations'])) { $url = elgg_add_action_tokens_to_url(elgg_get_site_url()."action/groups/join?user_guid={$user->guid}&group_guid={$group->guid}"); ?> -
    - +
    + "action/groups/killinvitation?user_guid={$user->getGUID()}&group_guid={$group->getGUID()}", @@ -35,6 +35,6 @@ if (!empty($vars['invitations']) && is_array($vars['invitations'])) { } } else { - echo "

    " . elgg_echo('groups:invitations:none') . "

    "; + echo "

    " . elgg_echo('groups:invitations:none') . "

    "; } ?> \ No newline at end of file diff --git a/mod/groups/views/default/groups/membershiprequests.php b/mod/groups/views/default/groups/membershiprequests.php index 43058e89f..8d4fe5c88 100644 --- a/mod/groups/views/default/groups/membershiprequests.php +++ b/mod/groups/views/default/groups/membershiprequests.php @@ -6,9 +6,9 @@ if ($request instanceof ElggUser) { ?> -
    +
    "; + echo "
    "; echo elgg_view("profile/icon", array( 'entity' => $request, 'size' => 'small', @@ -18,7 +18,7 @@ $url = elgg_add_action_tokens_to_url(elgg_get_site_url()."action/groups/addtogroup?user_guid={$request->guid}&group_guid={$vars['entity']->guid}"); ?> -
    +
    $header)); return true; ?> -"> + + "pg/groups/activity/" . elgg_get_page_owner_guid(), + 'text' => elgg_echo('link:view:all'), + )); +?> +

    dbprefix}river.id, {$CONFIG->dbprefix}river.type, {$CONFIG->dbprefix}river.subtype, {$CONFIG->dbprefix}river.action_type, {$CONFIG->dbprefix}river.access_id, {$CONFIG->dbprefix}river.view, {$CONFIG->dbprefix}river.subject_guid, {$CONFIG->dbprefix}river.object_guid, {$CONFIG->dbprefix}river.posted FROM {$CONFIG->dbprefix}river INNER JOIN {$CONFIG->dbprefix}entities AS entities1 ON {$CONFIG->dbprefix}river.object_guid = entities1.guid INNER JOIN {$CONFIG->dbprefix}entities AS entities2 ON entities1.container_guid = entities2.guid WHERE entities2.guid = $group_guid OR {$CONFIG->dbprefix}river.object_guid = $group_guid ORDER BY posted DESC limit {$offset},{$limit}"; $items = get_data($sql); diff --git a/mod/groups/views/default/groups/profile/buttons.php b/mod/groups/views/default/groups/profile/buttons.php index 31df7a5b5..0aef3920b 100644 --- a/mod/groups/views/default/groups/profile/buttons.php +++ b/mod/groups/views/default/groups/profile/buttons.php @@ -3,6 +3,8 @@ * Content header action buttons * * @uses $vars['entity'] + * + * @todo This should be done by registering menu items with the page actions menu */ if (!elgg_is_logged_in()) { @@ -47,7 +49,7 @@ if ($actions) { echo elgg_view('output/url', array( 'text' => $action, 'href' => $url, - 'class' => 'elgg-button-action', + 'class' => 'elgg-button elgg-button-action', )); } } diff --git a/mod/groups/views/default/groups/profile/profile_block.php b/mod/groups/views/default/groups/profile/profile_block.php index a0d41ba14..aec8fc6cd 100644 --- a/mod/groups/views/default/groups/profile/profile_block.php +++ b/mod/groups/views/default/groups/profile/profile_block.php @@ -18,8 +18,8 @@ $owner = $group->getOwnerEntity(); $profile_fields = elgg_get_config('group'); ?> -
    -
    +
    +
    '')); ?>
    @@ -41,7 +41,7 @@ $profile_fields = elgg_get_config('group');
    -
    +
    0) { diff --git a/mod/groups/views/default/groups/profile/widgets.php b/mod/groups/views/default/groups/profile/widgets.php index 76fa08647..08cbf1dae 100644 --- a/mod/groups/views/default/groups/profile/widgets.php +++ b/mod/groups/views/default/groups/profile/widgets.php @@ -16,7 +16,7 @@ echo "
    "; diff --git a/mod/groups/views/default/groups/sidebar/members.php b/mod/groups/views/default/groups/sidebar/members.php index 711b99f34..669d2c6bd 100644 --- a/mod/groups/views/default/groups/sidebar/members.php +++ b/mod/groups/views/default/groups/sidebar/members.php @@ -13,7 +13,7 @@ $all_link = elgg_view('output/url', array( $body = ''; $body .= "
    $all_link
    "; -- cgit v1.2.3