aboutsummaryrefslogtreecommitdiff
path: root/mod/logbrowser/views
diff options
context:
space:
mode:
authorben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-08-07 10:23:38 +0000
committerben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-08-07 10:23:38 +0000
commita65cdd21f234c8a07c90e54f9e9a0b1f33a972c2 (patch)
treea462d06cc0f34b56d547b07c5df3005b10260d1b /mod/logbrowser/views
parentf4ac146f927ff75822baadbb15f1beea89eaace6 (diff)
downloadelgg-a65cdd21f234c8a07c90e54f9e9a0b1f33a972c2.tar.gz
elgg-a65cdd21f234c8a07c90e54f9e9a0b1f33a972c2.tar.bz2
Initial changes to log browser
git-svn-id: https://code.elgg.org/elgg/trunk@1745 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/logbrowser/views')
-rw-r--r--mod/logbrowser/views/default/logbrowser/gallery.php34
-rw-r--r--mod/logbrowser/views/default/logbrowser/listing.php40
-rw-r--r--mod/logbrowser/views/default/object/logwrapper.php61
3 files changed, 43 insertions, 92 deletions
diff --git a/mod/logbrowser/views/default/logbrowser/gallery.php b/mod/logbrowser/views/default/logbrowser/gallery.php
deleted file mode 100644
index fb3a7537d..000000000
--- a/mod/logbrowser/views/default/logbrowser/gallery.php
+++ /dev/null
@@ -1,34 +0,0 @@
-<?php
- /**
- * Elgg log browser.
- *
- * @package ElggLogBrowser
- * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
- * @author Marcus Povey
- * @copyright Curverider Ltd 2008
- * @link http://elgg.com/
- */
-
- $entry = $vars['entity']->entry;
-
-
- $by = get_entity($entry->performed_by_guid);
- $object = get_object_from_log_entry($entry->id);
-
- if (is_callable(array($object, 'getURL')))
- $obj_url = $object->getURL();
-
-
- $info .= "<p><b>";
- if ($obj_url) $info .= "<a href=\"$obj_url\">";
- $info .= "{$entry->object_class}";
- if ($obj_url) $info .= "</a>";
- $info .= " " . elgg_echo($entry->event) . "</b></p>";
-
-
- $info .= "<div>";
- if ($by) $info .= elgg_echo('by') . " <a href=\"".$by->getURL()."\">{$by->name}</a> ";
- $info .= " " .date('r', $entry->time_created )."</div>";
-
- echo elgg_view_listing($icon, $info);
-?> \ No newline at end of file
diff --git a/mod/logbrowser/views/default/logbrowser/listing.php b/mod/logbrowser/views/default/logbrowser/listing.php
deleted file mode 100644
index 9550dba2e..000000000
--- a/mod/logbrowser/views/default/logbrowser/listing.php
+++ /dev/null
@@ -1,40 +0,0 @@
-<?php
- /**
- * Elgg log browser.
- *
- * @package ElggLogBrowser
- * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
- * @author Marcus Povey
- * @copyright Curverider Ltd 2008
- * @link http://elgg.com/
- */
-
- $entry = $vars['entity']->entry;
-
-
- $by = get_entity($entry->performed_by_guid);
- $object = get_object_from_log_entry($entry->id);
-
- if (is_callable(array($object, 'getURL')))
- $obj_url = $object->getURL();
-
- $icon = elgg_view(
- "graphics/icon", array(
- 'entity' => $vars['entity'],
- 'size' => 'small',
- )
- );
-
- $info .= "<p><b>";
- if ($obj_url) $info .= "<a href=\"$obj_url\">";
- $info .= "{$entry->object_class}";
- if ($obj_url) $info .= "</a>";
- $info .= " " . elgg_echo($entry->event) . "</b></p>";
-
-
- $info .= "<div>";
- if ($by) $info .= elgg_echo('by') . " <a href=\"".$by->getURL()."\">{$by->name}</a> ";
- $info .= " " .date('r', $entry->time_created )."</div>";
-
- echo elgg_view_listing($icon, $info);
-?> \ No newline at end of file
diff --git a/mod/logbrowser/views/default/object/logwrapper.php b/mod/logbrowser/views/default/object/logwrapper.php
index 673d732e8..8450c9b66 100644
--- a/mod/logbrowser/views/default/object/logwrapper.php
+++ b/mod/logbrowser/views/default/object/logwrapper.php
@@ -1,18 +1,43 @@
-<?php
- /**
- * Elgg log browser.
- *
- * @package ElggLogBrowser
- * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
- * @author Marcus Povey
- * @copyright Curverider Ltd 2008
- * @link http://elgg.com/
- */
-
- if (get_input('search_viewtype') == "gallery") {
- echo elgg_view('logbrowser/gallery',$vars);
- } else {
- echo elgg_view("logbrowser/listing",$vars);
- }
-
-?> \ No newline at end of file
+<?php
+ /**
+ * Elgg log browser.
+ *
+ * @package ElggLogBrowser
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Marcus Povey
+ * @copyright Curverider Ltd 2008
+ * @link http://elgg.com/
+ */
+
+ $entry = $vars['entity']->entry;
+
+ $by = get_entity($entry->performed_by_guid);
+ $object = get_object_from_log_entry($entry->id);
+
+ if (is_callable(array($object, 'getURL')))
+ $obj_url = $object->getURL();
+
+ //echo elgg_view_listing($icon, $info);
+?>
+ <table class="log_entry">
+ <tr>
+ <td class="log_entry_user">
+ <?php if ($by) {echo "<a href=\"".$by->getURL()."\">{$by->name}</a>"; } else echo "&nbsp;"; ?>
+ <td>
+ <td class="log_entry_time">
+ <?php echo date('r', $entry->time_created ); ?>
+ </td>
+ <td class="log_entry_item">
+ <?php
+ if ($obj_url) $info .= "<a href=\"$obj_url\">";
+ $info .= "{$entry->object_class}";
+ if ($obj_url) $info .= "</a>";
+ ?>
+ </td>
+ <td class="log_entry_action">
+ <div class="log_entry_action_<?php echo $entry->event; ?>">
+ <?php echo elgg_echo($entry->event); ?>
+ </div>
+ </td>
+ </tr>
+ </table> \ No newline at end of file