From 315ca19d2b96f7a0516fe7f0b611a48edae75824 Mon Sep 17 00:00:00 2001 From: "lpsolit%gmail.com" <> Date: Sun, 26 Feb 2006 07:40:23 +0000 Subject: Bug 225162: We need a UI for viewing the profiles_activity table - Patch by GavinS r=LpSolit a=justdave --- editusers.cgi | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'editusers.cgi') diff --git a/editusers.cgi b/editusers.cgi index 47b51c4cb..6e56a3847 100755 --- a/editusers.cgi +++ b/editusers.cgi @@ -17,6 +17,8 @@ # Lance Larsh # Frédéric Buclin # David Lawrence +# Vlad Dascalu +# Gavin Shelley use strict; use lib "."; @@ -730,6 +732,29 @@ if ($action eq 'search') { Bugzilla::BugMail::Send($_); } +########################################################################### +} elsif ($action eq 'activity') { + my $otherUser = check_user($otherUserID, $otherUserLogin); + + $vars->{'profile_changes'} = $dbh->selectall_arrayref( + "SELECT profiles.login_name AS who, " . + $dbh->sql_date_format('profiles_activity.profiles_when') . " AS activity_when, + fielddefs.description AS what, + profiles_activity.oldvalue AS removed, + profiles_activity.newvalue AS added + FROM profiles_activity + INNER JOIN profiles ON profiles_activity.who = profiles.userid + INNER JOIN fielddefs ON fielddefs.fieldid = profiles_activity.fieldid + WHERE profiles_activity.userid = ? + ORDER BY profiles_activity.profiles_when", + {'Slice' => {}}, + $otherUser->id); + + $vars->{'otheruser'} = $otherUser; + + $template->process("account/profile-activity.html.tmpl", $vars) + || ThrowTemplateError($template->error()); + ########################################################################### } else { $vars->{'action'} = $action; -- cgit v1.2.3-24-g4f1b