UX: Add link to change username on admin page

This commit is contained in:
Robin Ward 2014-08-27 13:52:01 -04:00
parent b1c0a3d01c
commit 09ea159afc
2 changed files with 33 additions and 20 deletions

View File

@ -1,25 +1,32 @@
<section class='details'>
<div class='user-controls'>
{{#link-to 'user' model class="btn"}}
<i class='fa fa-user'></i>
{{i18n admin.user.show_public_profile}}
{{/link-to}}
{{#if can_impersonate}}
<button class='btn' {{action impersonate target="content"}}>
<i class='fa fa-crosshairs'></i>
{{i18n admin.user.impersonate}}
</button>
{{/if}}
{{#if currentUser.admin}}
<button class='btn' {{action log_out target="content"}}>
<i class='fa fa-power-off'></i>
{{i18n admin.user.log_out}}
</button>
{{/if}}
</div>
<div class='display-row'>
<div class='field'>{{i18n user.username.title}}</div>
<div class='value'>{{username}}</div>
<div class='controls'>
{{#link-to 'user' model class="btn"}}
<i class='fa fa-user'></i>
{{i18n admin.user.show_public_profile}}
{{#link-to 'preferences.username' model class="btn"}}
<i class='fa fa-pencil'></i>
{{i18n user.change_username.title}}
{{/link-to}}
{{#if can_impersonate}}
<button class='btn' {{action impersonate target="content"}}>
<i class='fa fa-crosshairs'></i>
{{i18n admin.user.impersonate}}
</button>
{{/if}}
{{#if currentUser.admin}}
<button class='btn' {{action log_out target="content"}}>
<i class='fa fa-power-off'></i>
{{i18n admin.user.log_out}}
</button>
{{/if}}
</div>
</div>

View File

@ -284,11 +284,11 @@ td.flaggers td {
section.details {
h1 {
font-size: 15px;
background-color: scale-color-diff();
color: $secondary;
padding: 0 10px;
margin: 0 0 5px 0;
font-size: 18px;
color: $primary;
padding: 5px 10px;
margin: 30px 0 5px 0;
border-bottom: 5px solid scale-color-diff();
}
}
@ -301,6 +301,12 @@ section.details {
width: 1075px;
}
.user-controls {
padding: 5px;
clear: both;
text-align: right;
}
.display-row {
line-height: 30px;
padding: 5px;