mirror of
https://github.com/BookStackApp/BookStack.git
synced 2024-11-24 03:42:32 +01:00
Fixed incorrect role showing
This commit is contained in:
parent
598fd7811b
commit
a5807097e2
@ -3,7 +3,7 @@
|
||||
@foreach($options as $option)
|
||||
<option value="{{$option->id}}"
|
||||
@if($errors->has($name)) class="neg" @endif
|
||||
@if(isset($model) || old($name)) @if(old($name) && old($name) === $option->id) selected @elseif(isset($model) && $model->id === $option->id) selected @endif @endif
|
||||
@if(isset($model) || old($name)) @if(old($name) && old($name) === $option->id) selected @elseif(isset($model) && $model->role->id === $option->id) selected @endif @endif
|
||||
>
|
||||
{{ $option->$displayKey }}
|
||||
</option>
|
@ -19,7 +19,7 @@
|
||||
@if($currentUser->can('user-update'))
|
||||
<div class="form-group">
|
||||
<label for="role">User Role</label>
|
||||
@include('form/model-select', ['name' => 'role', 'options' => \Oxbow\Role::all(), 'displayKey' => 'display_name'])
|
||||
@include('form.role-select', ['name' => 'role', 'options' => \Oxbow\Role::all(), 'displayKey' => 'display_name'])
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user