mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-24 21:24:13 -08:00
Fixed issue where admin users could disable activation when editing their own profile
This commit is contained in:
parent
890b613f71
commit
7a44da85a0
|
@ -331,16 +331,19 @@
|
|||
@if (config('app.lock_passwords'))
|
||||
<div class="icheckbox disabled" style="padding-left: 10px;">
|
||||
<input type="checkbox" value="1" name="activated" class="minimal disabled" {{ (old('activated', $user->activated)) == '1' ? ' checked="checked"' : '' }} disabled="disabled">
|
||||
<!-- this is necessary because the field is disabled and will reset -->
|
||||
<input type="hidden" name="activated" value="{{ $user->activated }}">
|
||||
{{ trans('admin/users/general.activated_help_text') }}
|
||||
<p class="help-block">{{ trans('general.feature_disabled') }}</p>
|
||||
kjasdhv
|
||||
|
||||
</div>
|
||||
@elseif ($user->id === Auth::user()->id)
|
||||
<div class="icheckbox disabled" style="padding-left: 10px;">
|
||||
<input type="checkbox" value="1" name="activated" class="minimal disabled" {{ (old('activated', $user->activated)) == '1' ? ' checked="checked"' : '' }} disabled="disabled">
|
||||
<input type="checkbox" value="1" name="activated" class="minimal disabled" checked="checked" disabled="disabled">
|
||||
<!-- this is necessary because the field is disabled and will reset -->
|
||||
<input type="hidden" name="activated" value="1">
|
||||
{{ trans('admin/users/general.activated_help_text') }}
|
||||
<p class="help-block">{{ trans('admin/users/general.activated_disabled_help_text') }}</p>
|
||||
|
||||
</div>
|
||||
@else
|
||||
<div style="padding-left: 10px;">
|
||||
|
|
Loading…
Reference in a new issue