aboutsummaryrefslogtreecommitdiff
path: root/engine/lib/system_log.php
diff options
context:
space:
mode:
authoricewing <icewing@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-06-06 10:53:42 +0000
committericewing <icewing@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-06-06 10:53:42 +0000
commit0ee5aeddcb8fd223418c8d0a5afc3df8287201a8 (patch)
tree230d5204d75e0869392e3889aca10dfe3a8dc8e4 /engine/lib/system_log.php
parent7dbc5cd43f911a381011f4d220a8490f3049c27d (diff)
downloadelgg-0ee5aeddcb8fd223418c8d0a5afc3df8287201a8.tar.gz
elgg-0ee5aeddcb8fd223418c8d0a5afc3df8287201a8.tar.bz2
Marcus Povey <marcus@dushka.co.uk>
* Limit to specific users and/or relationships git-svn-id: https://code.elgg.org/elgg/trunk@818 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/lib/system_log.php')
-rw-r--r--engine/lib/system_log.php13
1 files changed, 10 insertions, 3 deletions
diff --git a/engine/lib/system_log.php b/engine/lib/system_log.php
index fbb9f9d96..a9d0bfb38 100644
--- a/engine/lib/system_log.php
+++ b/engine/lib/system_log.php
@@ -44,29 +44,36 @@
* This is useful for checking access permissions etc on objects.
*/
public function getObjectFromID($id);
+
+ /**
+ * Return the GUID of the owner of this object.
+ */
+ public function getObjectOwnerGUID();
}
/**
* Retrieve the system log based on a number of parameters.
*
+ * @param int $by_user The user who initiated the event.
* @param string $event The event you are searching on.
* @param string $class The class of object it effects.
* @param int $limit Maximum number of responses to return.
* @param int $offset Offset of where to start.
*/
- function get_system_log($event = "", $class = "", $limit = 10, $offset = 0)
+ function get_system_log($by_user = "", $event = "", $class = "", $limit = 10, $offset = 0)
{
global $CONFIG;
+ $by_user = (int)$by_user;
$event = sanitise_string($event);
$class = sanitise_string($class);
$limit = (int)$limit;
$offset = (int)$offset;
- $access = get_access_list();
-
$where = array();
+ if ($by_user != "")
+ $where[] = "performed_by_guid=$by_user";
if ($event != "")
$where[] = "event='$event'";
if ($class!=="")