#9: Users management section now works with Bootstrap v4
This commit is contained in:
parent
d15ff4ec6f
commit
00328c7ba2
@ -111,7 +111,7 @@ class UserController extends Controller
|
||||
* @param int $id
|
||||
* @return \Illuminate\Http\Response
|
||||
*/
|
||||
public function edit($id)
|
||||
public function edit(Request $request, $id)
|
||||
{
|
||||
$this->authorize('admin-access');
|
||||
|
||||
@ -128,6 +128,11 @@ class UserController extends Controller
|
||||
$usersGroups[] = $group->id;
|
||||
}
|
||||
|
||||
if (!$request->session()->has('_old_input'))
|
||||
{
|
||||
$request->session()->flash('_old_input', $user->toArray());
|
||||
}
|
||||
|
||||
return Theme::render('admin.edit_user', ['user' => $user, 'groups' => $groups, 'users_groups' => $usersGroups]);
|
||||
}
|
||||
|
||||
|
@ -2,102 +2,98 @@
|
||||
@section('title', trans('admin.create_user'))
|
||||
|
||||
@section('breadcrumb')
|
||||
<div class="breadcrumb">
|
||||
<div class="container">
|
||||
<ol class="breadcrumb">
|
||||
<li><a href="{{ route('home') }}"><i class="fa fa-fw fa-home"></i></a></li>
|
||||
<li><a href="{{ route('admin') }}">@lang('navigation.breadcrumb.admin')</a></li>
|
||||
<li><a href="{{ route('users.index') }}">@lang('navigation.breadcrumb.users')</a></li>
|
||||
<li class="active">@lang('navigation.breadcrumb.create_user')</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
<li class="breadcrumb-item"><a href="{{ route('home') }}"><i class="fa fa-fw fa-home"></i></a></li>
|
||||
<li class="breadcrumb-item"><a href="{{ route('admin') }}">@lang('navigation.breadcrumb.admin')</a></li>
|
||||
<li class="breadcrumb-item"><a href="{{ route('users.index') }}">@lang('navigation.breadcrumb.users')</a></li>
|
||||
<li class="breadcrumb-item active">@lang('navigation.breadcrumb.create_user')</li>
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
<div class="col">
|
||||
<h1>@lang('admin.create_user_title')</h1>
|
||||
<p>@lang('admin.create_user_intro')</p>
|
||||
<hr/>
|
||||
|
||||
{!! Form::open(['route' => 'users.store', 'method' => 'POST']) !!}
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('name') ? ' has-error' : '' }}">
|
||||
{!! Form::label('name', trans('forms.name_label'), ['class' => 'control-label']) !!}
|
||||
{!! Form::text('name', old('name'), ['class' => 'form-control']) !!}
|
||||
<form action="{{ route('users.store') }}" method="post">
|
||||
{{ csrf_field() }}
|
||||
|
||||
@if ($errors->has('name'))
|
||||
<span class="help-block">
|
||||
<strong>{{ $errors->first('name') }}</strong>
|
||||
</span>
|
||||
@endif
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('name') ? ' has-danger' : '' }}">
|
||||
<label class="form-control-label" for="user-name">@lang('forms.name_label')</label>
|
||||
<input type="text" class="form-control" id="user-name" name="name" value="{{ old('name') }}">
|
||||
|
||||
@if ($errors->has('name'))
|
||||
<div class="form-control-feedback">
|
||||
<strong>{{ $errors->first('name') }}</strong>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('email') ? ' has-danger' : '' }}">
|
||||
<label class="form-control-label" for="user-email">@lang('forms.email_label')</label>
|
||||
<input type="text" class="form-control" id="user-email" name="email" value="{{ old('email') }}">
|
||||
|
||||
@if ($errors->has('email'))
|
||||
<div class="form-control-feedback">
|
||||
<strong>{{ $errors->first('email') }}</strong>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('email') ? ' has-error' : '' }}">
|
||||
{!! Form::label('email', trans('forms.email_label'), ['class' => 'control-label']) !!}
|
||||
{!! Form::text('email', old('email'), ['class' => 'form-control']) !!}
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('password') ? ' has-danger' : '' }}">
|
||||
<label class="form-control-label" for="user-password">@lang('forms.password_label')</label>
|
||||
<input type="password" class="form-control" id="user-password" name="password" value="{{ old('password') }}">
|
||||
|
||||
@if ($errors->has('email'))
|
||||
<span class="help-block">
|
||||
<strong>{{ $errors->first('email') }}</strong>
|
||||
</span>
|
||||
@endif
|
||||
@if ($errors->has('password'))
|
||||
<div class="form-control-feedback">
|
||||
<strong>{{ $errors->first('password') }}</strong>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('password') ? ' has-error' : '' }}">
|
||||
{!! Form::label('password', trans('forms.password_label'), ['class' => 'control-label']) !!}
|
||||
{!! Form::password('password', ['class' => 'form-control']) !!}
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('password_confirmation') ? ' has-danger' : '' }}">
|
||||
<label class="form-control-label" for="user-password-confirm">@lang('forms.password_confirm_label')</label>
|
||||
<input type="password" class="form-control" id="user-password-confirm" name="password_confirmation" value="{{ old('password_confirmation') }}">
|
||||
|
||||
@if ($errors->has('password'))
|
||||
<span class="help-block">
|
||||
<strong>{{ $errors->first('password') }}</strong>
|
||||
</span>
|
||||
@endif
|
||||
@if ($errors->has('password_confirmation'))
|
||||
<div class="form-control-feedback">
|
||||
<strong>{{ $errors->first('password_confirmation') }}</strong>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('password_confirmation') ? ' has-error' : '' }}">
|
||||
{!! Form::label('password_confirmation', trans('forms.password_confirm_label'), ['class' => 'control-label']) !!}
|
||||
{!! Form::password('password_confirmation', ['class' => 'form-control']) !!}
|
||||
|
||||
@if ($errors->has('password_confirmation'))
|
||||
<span class="help-block">
|
||||
<strong>{{ $errors->first('password_confirmation') }}</strong>
|
||||
</span>
|
||||
@endif
|
||||
</div>
|
||||
<div class="form-check">
|
||||
<label class="form-check-label">
|
||||
<input class="form-check-input" type="checkbox" name="is_admin">
|
||||
@lang('forms.admin_user_label')
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" name="is_admin">
|
||||
<strong>@lang('forms.admin_user_label')</strong>
|
||||
</label>
|
||||
</div>
|
||||
<div class="form-check">
|
||||
<label class="form-check-label">
|
||||
<input class="form-check-input" type="checkbox" name="can_create_albums">
|
||||
@lang('forms.can_create_albums_label')
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" name="can_create_albums">
|
||||
<strong>@lang('forms.can_create_albums_label')</strong>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="form-actions">
|
||||
<a href="{{ route('users.index') }}" class="btn btn-default">@lang('forms.cancel_action')</a>
|
||||
<button type="submit" class="btn btn-success"><i class="fa fa-fw fa-check"></i> @lang('forms.create_action')</button>
|
||||
</div>
|
||||
{!! Form::close() !!}
|
||||
<div class="text-right">
|
||||
<a href="{{ route('users.index') }}" class="btn btn-link">@lang('forms.cancel_action')</a>
|
||||
<button type="submit" class="btn btn-success"><i class="fa fa-fw fa-check"></i> @lang('forms.create_action')</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -2,32 +2,31 @@
|
||||
@section('title', trans('admin.delete_user', ['name' => $user->name]))
|
||||
|
||||
@section('breadcrumb')
|
||||
<div class="breadcrumb">
|
||||
<div class="container">
|
||||
<ol class="breadcrumb">
|
||||
<li><a href="{{ route('home') }}"><i class="fa fa-fw fa-home"></i></a></li>
|
||||
<li><a href="{{ route('admin') }}">@lang('navigation.breadcrumb.admin')</a></li>
|
||||
<li><a href="{{ route('users.index') }}">@lang('navigation.breadcrumb.users')</a></li>
|
||||
<li class="active">@lang('navigation.breadcrumb.delete_user')</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
<li class="breadcrumb-item"><a href="{{ route('home') }}"><i class="fa fa-fw fa-home"></i></a></li>
|
||||
<li class="breadcrumb-item"><a href="{{ route('admin') }}">@lang('navigation.breadcrumb.admin')</a></li>
|
||||
<li class="breadcrumb-item"><a href="{{ route('users.index') }}">@lang('navigation.breadcrumb.users')</a></li>
|
||||
<li class="breadcrumb-item active">@lang('navigation.breadcrumb.delete_user')</li>
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
<h1>@yield('title')</h1>
|
||||
<p>@lang('admin.delete_user_confirm', ['name' => $user->name])</p>
|
||||
<div class="alert alert-danger">
|
||||
@lang('admin.delete_user_warning')
|
||||
</div>
|
||||
<div class="form-actions">
|
||||
{!! Form::open(['route' => ['users.destroy', $user->id], 'method' => 'DELETE']) !!}
|
||||
<a href="{{ route('users.index') }}" class="btn btn-default">@lang('forms.cancel_action')</a>
|
||||
<button type="submit" class="btn btn-danger"><i class="fa fa-fw fa-trash"></i> @lang('forms.delete_action')</button>
|
||||
{!! Form::close() !!}
|
||||
<div class="col-md-8 offset-md-2">
|
||||
<div class="card card-outline-danger">
|
||||
<div class="card-header card-danger">@yield('title')</div>
|
||||
<div class="card-block">
|
||||
<p>@lang('admin.delete_user_confirm', ['name' => $user->name])</p>
|
||||
<p class="text-danger"><b>@lang('admin.delete_user_warning')</b></p>
|
||||
|
||||
<div class="text-right">
|
||||
<form action="{{ route('users.destroy', [$user->id]) }}" method="post">
|
||||
{{ csrf_field() }}
|
||||
{{ method_field('DELETE') }}
|
||||
<a href="{{ route('users.index') }}" class="btn btn-link">@lang('forms.cancel_action')</a>
|
||||
<button type="submit" class="btn btn-danger"><i class="fa fa-fw fa-trash"></i> @lang('forms.delete_action')</button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -2,142 +2,139 @@
|
||||
@section('title', trans('admin.edit_user_title', ['name' => $user->name]))
|
||||
|
||||
@section('breadcrumb')
|
||||
<div class="breadcrumb">
|
||||
<div class="container">
|
||||
<ol class="breadcrumb">
|
||||
<li><a href="{{ route('home') }}"><i class="fa fa-fw fa-home"></i></a></li>
|
||||
<li><a href="{{ route('admin') }}">@lang('navigation.breadcrumb.admin')</a></li>
|
||||
<li><a href="{{ route('users.index') }}">@lang('navigation.breadcrumb.users')</a></li>
|
||||
<li class="active">@lang('navigation.breadcrumb.edit_user')</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
<li class="breadcrumb-item"><a href="{{ route('home') }}"><i class="fa fa-fw fa-home"></i></a></li>
|
||||
<li class="breadcrumb-item"><a href="{{ route('admin') }}">@lang('navigation.breadcrumb.admin')</a></li>
|
||||
<li class="breadcrumb-item"><a href="{{ route('users.index') }}">@lang('navigation.breadcrumb.users')</a></li>
|
||||
<li class="breadcrumb-item active">@lang('navigation.breadcrumb.edit_user')</li>
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
<div class="col">
|
||||
<h1>@yield('title')</h1>
|
||||
<p>@lang('admin.edit_user_intro')</p>
|
||||
<hr/>
|
||||
|
||||
{!! Form::model($user, ['route' => ['users.update', $user->id], 'method' => 'PUT']) !!}
|
||||
<div>
|
||||
{{-- Nav tabs --}}
|
||||
<ul class="nav nav-tabs" role="tablist">
|
||||
@include(Theme::viewName('partials.tab'), ['active_tab' => 'details', 'tab_name' => 'details', 'tab_icon' => 'info-circle', 'tab_text' => trans('admin.user_details_tab')])
|
||||
@include(Theme::viewName('partials.tab'), ['active_tab' => 'details', 'tab_name' => 'groups', 'tab_icon' => 'users', 'tab_text' => trans('admin.user_groups_tab')])
|
||||
</ul>
|
||||
<form action="{{ route('users.update', [$user->id]) }}" method="post">
|
||||
{{ csrf_field() }}
|
||||
{{ method_field('PUT') }}
|
||||
|
||||
{{-- Tab panes --}}
|
||||
<div class="tab-content">
|
||||
{{-- Details --}}
|
||||
<div role="tabpanel" class="tab-pane active" id="details-tab">
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('name') ? ' has-error' : '' }}">
|
||||
{!! Form::label('name', trans('forms.name_label'), ['class' => 'control-label']) !!}
|
||||
{!! Form::text('name', old('name'), ['class' => 'form-control']) !!}
|
||||
<div>
|
||||
{{-- Nav tabs --}}
|
||||
<ul class="nav nav-tabs" role="tablist">
|
||||
@include(Theme::viewName('partials.tab'), ['active_tab' => 'details', 'tab_name' => 'details', 'tab_icon' => 'info-circle', 'tab_text' => trans('admin.user_details_tab')])
|
||||
@include(Theme::viewName('partials.tab'), ['active_tab' => 'details', 'tab_name' => 'groups', 'tab_icon' => 'users', 'tab_text' => trans('admin.user_groups_tab')])
|
||||
</ul>
|
||||
|
||||
@if ($errors->has('name'))
|
||||
<span class="help-block">
|
||||
<strong>{{ $errors->first('name') }}</strong>
|
||||
</span>
|
||||
@endif
|
||||
{{-- Tab panes --}}
|
||||
<div class="tab-content">
|
||||
{{-- Details --}}
|
||||
<div role="tabpanel" class="tab-pane active" id="details-tab">
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('name') ? ' has-danger' : '' }}">
|
||||
<label class="form-control-label" for="user-name">@lang('forms.name_label')</label>
|
||||
<input type="text" class="form-control" id="user-name" name="name" value="{{ old('name') }}">
|
||||
|
||||
@if ($errors->has('name'))
|
||||
<div class="form-control-feedback">
|
||||
<strong>{{ $errors->first('name') }}</strong>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('email') ? ' has-danger' : '' }}">
|
||||
<label class="form-control-label" for="user-email">@lang('forms.email_label')</label>
|
||||
<input type="text" class="form-control" id="user-email" name="email" value="{{ old('email') }}">
|
||||
|
||||
@if ($errors->has('email'))
|
||||
<div class="form-control-feedback">
|
||||
<strong>{{ $errors->first('email') }}</strong>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('email') ? ' has-error' : '' }}">
|
||||
{!! Form::label('email', trans('forms.email_label'), ['class' => 'control-label']) !!}
|
||||
{!! Form::text('email', old('email'), ['class' => 'form-control']) !!}
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('password') ? ' has-danger' : '' }}">
|
||||
<label class="form-control-label" for="user-password">@lang('forms.password_label')</label>
|
||||
<input type="password" class="form-control" id="user-password" name="password" value="{{ old('password') }}">
|
||||
|
||||
@if ($errors->has('email'))
|
||||
<span class="help-block">
|
||||
<strong>{{ $errors->first('email') }}</strong>
|
||||
</span>
|
||||
@endif
|
||||
@if ($errors->has('password'))
|
||||
<div class="form-control-feedback">
|
||||
<strong>{{ $errors->first('password') }}</strong>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('password') ? ' has-error' : '' }}">
|
||||
{!! Form::label('password', trans('forms.password_label'), ['class' => 'control-label']) !!}
|
||||
{!! Form::password('password', ['class' => 'form-control']) !!}
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('password_confirmation') ? ' has-danger' : '' }}">
|
||||
<label class="form-control-label" for="user-password-confirm">@lang('forms.password_confirm_label')</label>
|
||||
<input type="password" class="form-control" id="user-password-confirm" name="password_confirmation" value="{{ old('password_confirmation') }}">
|
||||
|
||||
@if ($errors->has('password'))
|
||||
<span class="help-block">
|
||||
<strong>{{ $errors->first('password') }}</strong>
|
||||
</span>
|
||||
@endif
|
||||
@if ($errors->has('password_confirmation'))
|
||||
<div class="form-control-feedback">
|
||||
<strong>{{ $errors->first('password_confirmation') }}</strong>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-sm-6">
|
||||
<div class="form-group{{ $errors->has('password_confirmation') ? ' has-error' : '' }}">
|
||||
{!! Form::label('password_confirmation', trans('forms.password_confirm_label'), ['class' => 'control-label']) !!}
|
||||
{!! Form::password('password_confirmation', ['class' => 'form-control']) !!}
|
||||
|
||||
@if ($errors->has('password_confirmation'))
|
||||
<span class="help-block">
|
||||
<strong>{{ $errors->first('password_confirmation') }}</strong>
|
||||
</span>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" name="is_admin"@if ($user->is_admin) checked="checked"@endif>
|
||||
<strong>@lang('forms.admin_user_label')</strong>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" name="can_create_albums"@if ($user->can_create_albums) checked="checked"@endif>
|
||||
<strong>@lang('forms.can_create_albums_label')</strong>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@if (!$user->is_activated)
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" name="is_activated">
|
||||
<strong>@lang('forms.activate_user_label')</strong>
|
||||
<div class="form-check">
|
||||
<label class="form-check-label">
|
||||
<input class="form-check-input" type="checkbox" name="is_admin"@if ($user->is_admin) checked="checked"@endif>
|
||||
@lang('forms.admin_user_label')
|
||||
</label>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
{{-- Groups --}}
|
||||
<div role="tabpanel" class="tab-pane" id="groups-tab">
|
||||
@if ($groups->count() > 0)
|
||||
<p style="margin-bottom: 20px;">@lang('admin.user_groups_list_select', ['name' => $user->name])</p>
|
||||
<div class="form-check">
|
||||
<label class="form-check-label">
|
||||
<input class="form-check-input" type="checkbox" name="can_create_albums"@if ($user->can_create_albums) checked="checked"@endif>
|
||||
@lang('forms.can_create_albums_label')
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@foreach ($groups as $group)
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" name="user_group_id[]" value="{{ $group->id }}"@if (in_array($group->id, $users_groups)) checked="checked"@endif>
|
||||
<strong>{{ $group->name }}</strong>
|
||||
@if (!$user->is_activated)
|
||||
<div class="form-check">
|
||||
<label class="form-check-label">
|
||||
<input class="form-check-input" type="checkbox" name="is_activated">
|
||||
<strong>@lang('forms.activate_user_label')</strong>
|
||||
</label>
|
||||
</div>
|
||||
@endforeach
|
||||
@else
|
||||
@endif
|
||||
@endif
|
||||
</div>
|
||||
|
||||
{{-- Groups --}}
|
||||
<div role="tabpanel" class="tab-pane" id="groups-tab">
|
||||
@if ($groups->count() > 0)
|
||||
<p style="margin-bottom: 20px;">@lang('admin.user_groups_list_select', ['name' => $user->name])</p>
|
||||
|
||||
@foreach ($groups as $group)
|
||||
<div class="form-check">
|
||||
<label class="form-check-label">
|
||||
<input class="form-check-input" type="checkbox" name="user_group_id[]" value="{{ $group->id }}"@if (in_array($group->id, $users_groups)) checked="checked"@endif>
|
||||
{{ $group->name }}
|
||||
</label>
|
||||
</div>
|
||||
@endforeach
|
||||
@else
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="text-right" style="margin-top: 20px;">
|
||||
<a href="{{ route('users.index') }}" class="btn btn-link">@lang('forms.cancel_action')</a>
|
||||
<button type="submit" class="btn btn-success"><i class="fa fa-fw fa-check"></i> @lang('forms.save_action')</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-actions" style="margin-top: 20px;">
|
||||
<a href="{{ route('users.index') }}" class="btn btn-default">@lang('forms.cancel_action')</a>
|
||||
<button type="submit" class="btn btn-success"><i class="fa fa-fw fa-check"></i> @lang('forms.save_action')</button>
|
||||
</div>
|
||||
</div>
|
||||
{!! Form::close() !!}
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -2,21 +2,15 @@
|
||||
@section('title', trans('admin.users_title'))
|
||||
|
||||
@section('breadcrumb')
|
||||
<div class="breadcrumb">
|
||||
<div class="container">
|
||||
<ol class="breadcrumb">
|
||||
<li><a href="{{ route('home') }}"><i class="fa fa-fw fa-home"></i></a></li>
|
||||
<li><a href="{{ route('admin') }}">@lang('navigation.breadcrumb.admin')</a></li>
|
||||
<li class="active">@lang('navigation.breadcrumb.users')</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
<li class="breadcrumb-item"><a href="{{ route('home') }}"><i class="fa fa-fw fa-home"></i></a></li>
|
||||
<li class="breadcrumb-item"><a href="{{ route('admin') }}">@lang('navigation.breadcrumb.admin')</a></li>
|
||||
<li class="breadcrumb-item active">@lang('navigation.breadcrumb.users')</li>
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
<div class="col">
|
||||
<h1>@lang('admin.list_users_title')</h1>
|
||||
<div class="alert alert-info" style="margin-bottom: 30px;">
|
||||
<p><i class="fa fa-fw fa-info"></i> @lang('admin.list_users_intro')</p>
|
||||
@ -27,8 +21,8 @@
|
||||
@foreach ($users as $user)
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-size: 1.3em;">{{ $user->name }}@if ($user->is_admin) <i class="fa fa-fw fa-cog"></i>@endif</span><br/>
|
||||
<a href="mailto:{{ $user->email }}">{{ $user->email }}</a>
|
||||
<span style="font-size: 1.3em;"><a href="{{ route('users.edit', ['id' => $user->id]) }}">{{ $user->name }}</a>@if ($user->is_admin) <i class="fa fa-fw fa-cog"></i>@endif</span><br/>
|
||||
{{ $user->email }} <a href="mailto:{{ $user->email }}"><i class="fa fa-fw fa-mail-forward"></i></a>
|
||||
</td>
|
||||
<td>
|
||||
@if (!$user->is_activated)
|
||||
@ -36,7 +30,6 @@
|
||||
@endif
|
||||
</td>
|
||||
<td class="text-right">
|
||||
<a href="{{ route('users.edit', ['id' => $user->id]) }}" class="btn btn-default">@lang('forms.edit_action')</a>
|
||||
<a href="{{ route('users.delete', ['id' => $user->id]) }}" class="btn btn-danger">@lang('forms.delete_action')</a>
|
||||
</td>
|
||||
</tr>
|
||||
@ -49,7 +42,7 @@
|
||||
</div>
|
||||
|
||||
<div class="pull-right" style="margin-top: 10px;">
|
||||
<a href="{{ route('groups.index') }}" class="btn btn-default">@lang('admin.list_groups_title')</a>
|
||||
<a href="{{ route('groups.index') }}" class="btn btn-link">@lang('admin.list_groups_title')</a>
|
||||
<a href="{{ route('users.create') }}" class="btn btn-success"><i class="fa fa-fw fa-plus"></i> @lang('admin.create_user')</a>
|
||||
</div>
|
||||
</div>
|
||||
|
Loading…
Reference in New Issue
Block a user