2 $modelType - The type of permission model; String matching one of: user, role, fallback
3 $modelId - The ID of the permission model.
4 $modelName - The name of the permission model.
5 $modelDescription - The description of the permission model.
6 $entityType - String identifier for type of entity having permissions applied.
7 $permission - The entity permission containing the permissions.
8 $inheriting - Boolean if the current row should be marked as inheriting default permissions. Used for "Everyone Else" role.
11 <div component="permissions-table" class="item-list-row flex-container-row justify-space-between wrap">
12 <div class="gap-x-m flex-container-row items-center px-l py-m flex">
13 <div class="text-large" title="{{ $modelType === 'fallback' ? trans('entities.permissions_role_everyone_else') : trans('common.role') }}">
14 @icon($modelType === 'fallback' ? 'groups' : 'role')
17 <strong>{{ $modelName }}</strong> <br>
18 <small class="text-muted">{{ $modelDescription }}</small>
20 @if($modelType !== 'fallback')
22 class="ml-auto flex-none text-small text-primary text-button hover-underline item-list-row-toggle-all hide-under-s"
23 refs="permissions-table@toggle-all"
24 ><strong>{{ trans('common.toggle_all') }}</strong></button>
27 @if($modelType === 'fallback')
28 <div class="px-l flex-container-row items-center" refs="entity-permissions@everyone-inherit">
29 @include('form.custom-checkbox', [
30 'name' => 'entity-permissions-inherit',
31 'label' => trans('entities.permissions_inherit_defaults'),
33 'checked' => $inheriting
37 <div class="flex-container-row justify-space-between gap-x-xl wrap items-center">
38 <input type="hidden" name="permissions[{{ $modelType }}][{{ $modelId }}][active]"
39 @if($inheriting) disabled="disabled" @endif
42 @include('form.custom-checkbox', [
43 'name' => 'permissions[' . $modelType . '][' . $modelId . '][view]',
44 'label' => trans('common.view'),
46 'checked' => $permission->view,
47 'disabled' => $inheriting
50 @if($entityType !== 'page')
52 @include('form.custom-checkbox', [
53 'name' => 'permissions[' . $modelType . '][' . $modelId . '][create]',
54 'label' => trans('common.create'),
56 'checked' => $permission->create,
57 'disabled' => $inheriting
62 @include('form.custom-checkbox', [
63 'name' => 'permissions[' . $modelType . '][' . $modelId . '][update]',
64 'label' => trans('common.update'),
66 'checked' => $permission->update,
67 'disabled' => $inheriting
71 @include('form.custom-checkbox', [
72 'name' => 'permissions[' . $modelType . '][' . $modelId . '][delete]',
73 'label' => trans('common.delete'),
75 'checked' => $permission->delete,
76 'disabled' => $inheriting
80 @if($modelType !== 'fallback')
81 <div class="flex-container-row items-center px-m py-s">
83 class="text-neg p-m icon-button"
84 data-model-type="{{ $modelType }}"
85 data-model-id="{{ $modelId }}"
86 data-model-name="{{ $modelName }}"
87 title="{{ trans('common.remove') }}">
88 @icon('close') <span class="hide-over-m ml-xs">{{ trans('common.remove') }}</span>