Admin users may make more admin users. Closes #795

This commit is contained in:
James Brooks
2015-08-02 14:16:00 +01:00
parent fb55beb47b
commit d2c8f414f6
2 changed files with 15 additions and 1 deletions

View File

@@ -127,7 +127,12 @@ return [
'password' => 'Password',
'api-token' => 'API Token',
'api-token-help' => 'Regenerating your API token will prevent existing applications from accessing Cachet.',
'2fa' => [
'user_level' => 'User Level',
'levels' => [
'admin' => 'Admin',
'user' => 'User',
],
'2fa' => [
'help' => 'Enabling two factor authentication increases security of your account. You will need to download <a href="https://support.google.com/accounts/answer/1066447?hl=en">Google Authenticator</a> or a similar app on to your mobile device. When you login you will be asked to provide a token generated by the app.',
],
],

View File

@@ -28,6 +28,15 @@
<label>{{ trans('forms.user.password') }}</label>
<input type="password" class="form-control" name="password" value="">
</div>
@if($loggedUser->isAdmin)
<div class="form-group">
<label>{{ trans('forms.user.user_level') }}</label>
<select name="level" class="form-control">
<option value="2" selected>{{ trans('forms.user.levels.user') }}</option>
<option value="1">{{ trans('forms.user.levels.admin') }}</option>
</select>
</div>
@endif
</fieldset>
<div class="form-group">