FEATURE: hopefully last changes about permissions

This commit is contained in:
Michal Kváček
2017-08-24 02:04:20 +02:00
parent b35149ad67
commit 49bd38db50
3 changed files with 12 additions and 18 deletions
@@ -8,7 +8,7 @@
{{str_limit($template->description, 150)}}
</div>
@can('copy', $template)
@can('copy', \App\Models\Templates\Template::class)
@if($isWritable)
<a data-template-id="{{$template->id}}" data-template-name="{{$template->template_name}}"
class="btn btn-pill-left btn-secondary col-lg-6 copy-template" data-toggle="tooltip"
@@ -21,11 +21,6 @@
<i class="fa fa-copy"></i>
</a>
@endif
@else
<a href="#" class="btn btn-pill-left btn-secondary disabled col-lg-6" data-toggle="tooltip"
title="@lang('admin/templates.cannotCopy')">
<i class="fa fa-copy"></i>
</a>
@endcan
@can('update', $template)
<a href="{{route('templates.edit', ['id' => $template->id])}}"
@@ -5,10 +5,10 @@
@section('headerButtons')
@can('manage', \App\Models\User::class)
<a href="{{route('users.overview')}}" class="btn btn-secondary btn-sm rounded"
title="@lang('admin/userManagement.overview')">
<i class="fa fa-list"></i>
</a>
<a href="{{route('users.overview')}}" class="btn btn-secondary btn-sm rounded"
title="@lang('admin/userManagement.overview')">
<i class="fa fa-list"></i>
</a>
@endcan
@endsection
@@ -112,13 +112,12 @@
@endforeach
</ul>
<div class="text-center">
<a href="{{route('log.overview', ['userId' => $user->id])}}"
class="btn btn-secondary">@lang('admin/userManagement.moreUserActions')</a>
</div>
@can('manage', \App\Models\ActionLog\ActionLog::class)
<div class="text-center">
<a href="{{route('log.overview', ['userId' => $user->id])}}"
class="btn btn-secondary">@lang('admin/userManagement.moreUserActions')</a>
</div>
@endcan
@else
<div class="alert alert-info">
<em>@lang('admin/userManagement.noActions')</em>