diff options
author | icewing <icewing@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-05-27 09:28:13 +0000 |
---|---|---|
committer | icewing <icewing@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-05-27 09:28:13 +0000 |
commit | 82362e03b337622ab65a37d1349f5213bdac0518 (patch) | |
tree | 615deb50dc32b46ed538d4509f3c1dbe20d3d002 | |
parent | 0ff9f9a00f97fd88fa7794adca3ff7b204fd2c5d (diff) | |
download | elgg-82362e03b337622ab65a37d1349f5213bdac0518.tar.gz elgg-82362e03b337622ab65a37d1349f5213bdac0518.tar.bz2 |
Marcus Povey <marcus@dushka.co.uk>
* Views looked for now river/$CLASSNAME/$EVENT
git-svn-id: https://code.elgg.org/elgg/trunk@720 36083f99-b078-4883-b0ff-0f9b5a30f544
-rw-r--r-- | engine/lib/river.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/engine/lib/river.php b/engine/lib/river.php index dd6da4801..7c8eaa327 100644 --- a/engine/lib/river.php +++ b/engine/lib/river.php @@ -14,7 +14,8 @@ /** * Extract a list of river events from the current system log. * This function retrieves the objects from the system log and will attempt to render - * the view "river/CLASSNAME" where CLASSNAME is the class of the object the system event is referring to. + * the view "river/CLASSNAME/EVENT" where CLASSNAME is the class of the object the system event is referring to, + * and EVENT is the event (create, update, delete etc). * * This view will be passed the log entry (as 'log_entry') and the object (as 'object') which will be accessable * through the $vars[] array. @@ -47,6 +48,7 @@ foreach ($log_events as $log) { // See if we have access to the object we're talking about + $event = $log->event; $class = $log->object_class; $tmp = new $class(); $object = $tmp->getObjectFromID($log->object_id); @@ -58,7 +60,7 @@ $tam = ""; // test if view exist and if so - $tam = elgg_view("river/$class", array( + $tam = elgg_view("river/$class/$event", array( 'log_entry' => $log, 'object' => $object )); |