[Rt-commit] r7390 - in rt/branches/3.7-EXPERIMENTAL: .
html/Admin/Users/Elements
ruz at bestpractical.com
ruz at bestpractical.com
Thu Mar 29 11:05:31 EDT 2007
Author: ruz
Date: Thu Mar 29 11:05:31 2007
New Revision: 7390
Added:
rt/branches/3.7-EXPERIMENTAL/html/Admin/Users/Elements/
rt/branches/3.7-EXPERIMENTAL/html/Admin/Users/Elements/ShowPublicKeyInfo
Modified:
rt/branches/3.7-EXPERIMENTAL/ (props changed)
rt/branches/3.7-EXPERIMENTAL/html/Admin/Users/Modify.html
Log:
r4836 at cubic-pc: cubic | 2007-03-29 17:43:54 +0400
* show user's public key if it's exists
Added: rt/branches/3.7-EXPERIMENTAL/html/Admin/Users/Elements/ShowPublicKeyInfo
==============================================================================
--- (empty file)
+++ rt/branches/3.7-EXPERIMENTAL/html/Admin/Users/Elements/ShowPublicKeyInfo Thu Mar 29 11:05:31 2007
@@ -0,0 +1,24 @@
+<&| /Widgets/TitleBox, title => loc('GnuPG Public Key') &>
+% if ( $res{'exit_code'} ) {
+<% loc('User has no public key') %>
+% } else {
+<table>
+<tr><th><% loc('User') %>:</th> <td><% $res{'info'}{'User'} %></td></tr>
+<tr><th><% loc('Trust') %>:</th> <td><% loc( $res{'info'}{'Trust'} ) %></td></tr>
+<tr><th><% loc('Created') %>:</th><td><% $res{'info'}{'Created'} %></td></tr>
+<tr><th><% loc('Expire') %>:</th> <td><% $res{'info'}{'Expire'} %></td></tr>
+</table>
+% }
+</&>
+
+<%ARGS>
+$UserObj
+</%ARGS>
+<%INIT>
+return unless $UserObj->EmailAddress;
+
+require RT::Crypt::GnuPG;
+my %res = RT::Crypt::GnuPG::GetPublicKeyInfo( $UserObj->EmailAddress );
+
+</%INIT>
+
Modified: rt/branches/3.7-EXPERIMENTAL/html/Admin/Users/Modify.html
==============================================================================
--- rt/branches/3.7-EXPERIMENTAL/html/Admin/Users/Modify.html (original)
+++ rt/branches/3.7-EXPERIMENTAL/html/Admin/Users/Modify.html Thu Mar 29 11:05:31 2007
@@ -232,6 +232,8 @@
</&>
% }
+<& Elements/ShowPublicKeyInfo, UserObj => $UserObj &>
+
</td>
</tr>
</table>
@@ -373,7 +375,7 @@
}
-# {{{ Do some setup for the ui
+# Do some setup for the ui
unless ( $UserObj->id && $UserObj->Disabled ) {
$EnabledChecked ="CHECKED";
}
@@ -382,8 +384,6 @@
$PrivilegedChecked = "CHECKED";
}
-# }}}
-
# set the id, so the the menu will have the right info, this needs to
# be done here to avoid creating and then modifying a user
$id = $UserObj->Id;
More information about the Rt-commit
mailing list