Commit 47d81cbd authored by Richard Mansfield's avatar Richard Mansfield

Change login-as back to a button; remove username from button text (bug #632062)

Signed-off-by: default avatarRichard Mansfield <richardm@catalyst.net.nz>
parent 19865a6c
......@@ -271,7 +271,7 @@ if (empty($suspended)) {
'reason' => array(
'type' => 'textarea',
'rows' => 5,
'cols' => 60,
'cols' => 28,
'title' => get_string('reason'),
'description' => get_string('suspendedreasondescription', 'admin'),
),
......@@ -532,12 +532,7 @@ $smarty->assign('siteform', $siteform);
$smarty->assign('institutions', count($allinstitutions) > 1);
$smarty->assign('institutionform', $institutionform);
if ($id != $USER->get('id') && is_null($USER->get('parentuser'))) {
$loginas = get_string('loginasuser', 'admin', $user->username);
} else {
$loginas = null;
}
$smarty->assign('loginas', $loginas);
$smarty->assign('loginas', $id != $USER->get('id') && is_null($USER->get('parentuser')));
$smarty->assign('PAGEHEADING', TITLE . ': ' . display_name($user));
# Only allow deletion and suspension of a user if the viewed user is not
......
......@@ -529,6 +529,7 @@ $string['basicdetails'] = '2 - Basic Details';
$string['create'] = '3 - Create';
// Login as
$string['loginas'] = 'Login as';
$string['loginasuser'] = 'Login as %s';
$string['becomeadminagain'] = 'Become %s again';
// Login-as exceptions
......
......@@ -326,6 +326,8 @@ table.tablerenderer th.desc {
background: #f6f6f6;
}
#profilepict a img {
width: 100px;
height: 100px;
padding: 0;
}
#profilename {
......
......@@ -21,7 +21,7 @@
<div id="profilename"><a href="{$WWWROOT}user/view.php?id={$user->id}">{$user|display_name|escape}</a></div>
</div>
{if $loginas}
<div id="loginas"><a href="{$WWWROOT}admin/users/changeuser.php?id={$user->id}">{$loginas}</a></div>
<div id="loginas"><a class="btn" href="{$WWWROOT}admin/users/changeuser.php?id={$user->id}">{str tag=loginas section=admin}</a></div>
{/if}
</td>
<td id="useraccountsettingsleft"><h2>{str tag="siteaccountsettings" section="admin"}</h2>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment