aboutsummaryrefslogtreecommitdiff
path: root/mod/groups/views
diff options
context:
space:
mode:
Diffstat (limited to 'mod/groups/views')
-rw-r--r--mod/groups/views/default/river/group/create.php2
-rw-r--r--mod/groups/views/default/river/relationship/member/create.php50
2 files changed, 13 insertions, 39 deletions
diff --git a/mod/groups/views/default/river/group/create.php b/mod/groups/views/default/river/group/create.php
index 961750974..aa9fef47a 100644
--- a/mod/groups/views/default/river/group/create.php
+++ b/mod/groups/views/default/river/group/create.php
@@ -5,7 +5,7 @@
$objecturl = $object->getURL();
$url = "<a href=\"{$performed_by->getURL()}\">{$performed_by->name}</a>";
- $string = sprintf(elgg_echo("groups:river:created"),$url) . " ";
+ $string = sprintf(elgg_echo("groups:river:create"), $url) . " ";
$string .= " <a href=\"" . $object->getURL() . "\">" . $object->name . "</a>";
$string .= " <span class='entity_subtext'>". elgg_view_friendly_time($object->time_created);
if (isloggedin()) {
diff --git a/mod/groups/views/default/river/relationship/member/create.php b/mod/groups/views/default/river/relationship/member/create.php
index e5e318ce0..a568920cc 100644
--- a/mod/groups/views/default/river/relationship/member/create.php
+++ b/mod/groups/views/default/river/relationship/member/create.php
@@ -1,40 +1,14 @@
<?php
- /**
- * Elgg relationship create event for groups
- * Display something in the river when a group is joined
- *
- * @package ElggGroups
- * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
- * @author Curverider Ltd
- * @copyright Curverider Ltd 2008-2010
- * @link http://elgg.com/
- */
- $statement = $vars['statement'];
-
- $performed_by = $statement->getSubject();
- $event = $statement->getEvent();
- $object = $statement->getObject();
-
- if (is_array($object))
- {
- switch ($object['relationship'])
- {
- // Friending
- case 'member' :
- $user = $object['subject'];
- $group = $object['object'];
-
- if (($user instanceof ElggUser) && ($group instanceof ElggGroup))
- {
- echo "<a href=\"{$user->getURL()}\">{$user->name}</a> ";
- echo elgg_echo("groups:river:member");
- echo " '<a href=\"{$group->getURL()}\">{$group->name}</a>'";
- }
-
- break;
- }
- }
-
-
-?> \ No newline at end of file
+ $performed_by = get_entity($vars['item']->subject_guid);
+ $object = get_entity($vars['item']->object_guid);
+ $objecturl = $object->getURL();
+
+ $url = "<a href=\"{$performed_by->getURL()}\">{$performed_by->name}</a>";
+ $string = sprintf(elgg_echo("groups:river:member"),$url) . " ";
+ $string .= " <a href=\"" . $object->getURL() . "\">" . $object->name . "</a>";
+ $string .= " <span class='entity_subtext'>". elgg_view_friendly_time($vars['item']->posted);
+ $string .= "</span>";
+?>
+
+<?php echo $string; ?> \ No newline at end of file