aboutsummaryrefslogtreecommitdiff
path: root/mod/groups/views/default
diff options
context:
space:
mode:
Diffstat (limited to 'mod/groups/views/default')
-rw-r--r--mod/groups/views/default/forms/groups/search.php3
-rw-r--r--mod/groups/views/default/groups/edit.php4
-rw-r--r--mod/groups/views/default/groups/group_sort_menu.php7
-rw-r--r--mod/groups/views/default/groups/profile/activity_module.php47
-rw-r--r--mod/groups/views/default/groups/side_menu.php5
-rw-r--r--mod/groups/views/default/groups/sidebar/members.php2
-rw-r--r--mod/groups/views/default/river/annotation/group_topic_post/reply.php1
-rw-r--r--mod/groups/views/default/river/relationship/member/create.php1
-rw-r--r--mod/groups/views/default/settings/groups/edit.php4
9 files changed, 23 insertions, 51 deletions
diff --git a/mod/groups/views/default/forms/groups/search.php b/mod/groups/views/default/forms/groups/search.php
index 8495fc186..ddf639b74 100644
--- a/mod/groups/views/default/forms/groups/search.php
+++ b/mod/groups/views/default/forms/groups/search.php
@@ -1,4 +1,7 @@
<?php
+/**
+ * Group tag-based search form body
+ */
$tag_string = elgg_echo('groups:search:tags');
diff --git a/mod/groups/views/default/groups/edit.php b/mod/groups/views/default/groups/edit.php
index 87fbaa182..2434bd14f 100644
--- a/mod/groups/views/default/groups/edit.php
+++ b/mod/groups/views/default/groups/edit.php
@@ -1,6 +1,8 @@
<?php
/**
- * Edit/create a group
+ * Edit/create a group wrapper
+ *
+ * @uses $vars['entity'] ElggGroup object
*/
$entity = elgg_extract('entity', $vars, null);
diff --git a/mod/groups/views/default/groups/group_sort_menu.php b/mod/groups/views/default/groups/group_sort_menu.php
index 6ba56628e..ef99a21a8 100644
--- a/mod/groups/views/default/groups/group_sort_menu.php
+++ b/mod/groups/views/default/groups/group_sort_menu.php
@@ -1,14 +1,15 @@
<?php
/**
- * All groups navigation menu
+ * All groups listing page navigation
+ *
+ * @todo should use navigation tab view
*/
$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 = elgg_get_site_url() . "pg/groups/all/";
?>
<div class="elgg-tabs mtm">
diff --git a/mod/groups/views/default/groups/profile/activity_module.php b/mod/groups/views/default/groups/profile/activity_module.php
index 1c7e6daa2..78eae9cec 100644
--- a/mod/groups/views/default/groups/profile/activity_module.php
+++ b/mod/groups/views/default/groups/profile/activity_module.php
@@ -2,11 +2,11 @@
/**
* Groups latest activity
*
+ * @todo add people joining group to activity
+ *
* @package Groups
*/
-global $CONFIG;
-
if ($vars['entity']->activity_enable == 'no') {
return true;
}
@@ -16,7 +16,6 @@ if (!$group) {
return true;
}
-
$all_link = elgg_view('output/url', array(
'href' => "pg/groups/activity/$group->guid",
'text' => elgg_echo('link:view:all'),
@@ -27,10 +26,11 @@ $header .= '<h3>' . elgg_echo('groups:activity') . '</h3>';
elgg_push_context('widgets');
+$db_prefix = elgg_get_config('dbprefix');
$content = elgg_list_river(array(
'limit' => 4,
'pagination' => false,
- 'joins' => array("join {$CONFIG->dbprefix}entities e1 on e1.guid = rv.object_guid"),
+ 'joins' => array("join {$db_prefix}entities e1 on e1.guid = rv.object_guid"),
'wheres' => array("(e1.container_guid = $group->guid)"),
));
elgg_pop_context();
@@ -40,42 +40,3 @@ if (!$content) {
}
echo elgg_view_module('info', '', $content, array('header' => $header));
-
-return true;
-?>
-<span class="group_widget_link">
-<?php
- echo elgg_view('output/url', array(
- 'href' => "pg/groups/activity/" . elgg_get_page_owner_guid(),
- 'text' => elgg_echo('link:view:all'),
- ));
-?>
-</span>
-<h3><?php echo elgg_echo("activity"); ?></h3>
-<?php
- $owner = elgg_get_page_owner_entity();
- $group_guid = $owner->guid;
- $limit = 5;
-
- $offset = (int) get_input('offset', 0);
-
- // Sanitise variables -- future proof in case they get sourced elsewhere
- $limit = (int) $limit;
- $offset = (int) $offset;
- $group_guid = (int) $group_guid;
-
- //@todo Holy cow, this really needs to be a function!
- $sql = "SELECT {$CONFIG->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);
-
- if (count($items) > 0) {
- $river_items = elgg_view('river/item/list',array(
- 'limit' => $limit,
- 'offset' => $offset,
- 'items' => $items
- ));
- }
- echo $river_items;
-
-?>
diff --git a/mod/groups/views/default/groups/side_menu.php b/mod/groups/views/default/groups/side_menu.php
index 0ae2bef63..df2314689 100644
--- a/mod/groups/views/default/groups/side_menu.php
+++ b/mod/groups/views/default/groups/side_menu.php
@@ -1,3 +1,8 @@
+<?php
+/**
+ * @todo move into start.php using register menu item function
+ */
+?>
<ul class="submenu page_navigation">
<?php
if(elgg_is_logged_in()){
diff --git a/mod/groups/views/default/groups/sidebar/members.php b/mod/groups/views/default/groups/sidebar/members.php
index 669d2c6bd..5f93022e7 100644
--- a/mod/groups/views/default/groups/sidebar/members.php
+++ b/mod/groups/views/default/groups/sidebar/members.php
@@ -2,6 +2,8 @@
/**
* Group members sidebar
*
+ * @todo clean up html
+ *
* @package ElggGroups
*/
diff --git a/mod/groups/views/default/river/annotation/group_topic_post/reply.php b/mod/groups/views/default/river/annotation/group_topic_post/reply.php
index f0b7d03b8..1999c8dd9 100644
--- a/mod/groups/views/default/river/annotation/group_topic_post/reply.php
+++ b/mod/groups/views/default/river/annotation/group_topic_post/reply.php
@@ -25,4 +25,3 @@ if ($reply) {
echo $excerpt;
echo '</div>';
}
-
diff --git a/mod/groups/views/default/river/relationship/member/create.php b/mod/groups/views/default/river/relationship/member/create.php
index 5123964c3..060826649 100644
--- a/mod/groups/views/default/river/relationship/member/create.php
+++ b/mod/groups/views/default/river/relationship/member/create.php
@@ -11,7 +11,6 @@ $params = array(
);
$link = elgg_view('output/url', $params);
-
echo elgg_echo('groups:river:join');
echo " $link";
diff --git a/mod/groups/views/default/settings/groups/edit.php b/mod/groups/views/default/settings/groups/edit.php
index 1cf6be466..7197dcb37 100644
--- a/mod/groups/views/default/settings/groups/edit.php
+++ b/mod/groups/views/default/settings/groups/edit.php
@@ -8,7 +8,7 @@ if (!isset($vars['entity']->hidden_groups)) {
$vars['entity']->hidden_groups = 'no';
}
-echo '<p>';
+echo '<div>';
echo elgg_echo('groups:allowhiddengroups');
echo ' ';
echo elgg_view('input/dropdown', array(
@@ -19,4 +19,4 @@ echo elgg_view('input/dropdown', array(
),
'value' => $vars['entity']->hidden_groups,
));
-echo '</p>';
+echo '</div>';