@extends('layouts.admin') @section('title', 'Manage Roles') @section('header_title', 'User Roles') @section('content')
No roles found. Create one to get started!
@else| Name | Guard | Users | Permissions | Module Access | Setting Group Access | Show on Reg. | Actions |
|---|---|---|---|---|---|---|---|
| {{ $role->name }} | {{ $role->guard_name }} | {{ $role->users_count }} | @if($role->permissions->count() > 0) @php $spatiePermissions = $role->permissions->pluck('name'); @endphp {{ $spatiePermissions->take(2)->implode(', ') }} @if($spatiePermissions->count() > 2) ... ({{ $spatiePermissions->count() }} total) @endif @else No permissions assigned @endif | @if(!empty($role->module_access_permissions)) @php $modulePerms = collect($role->module_access_permissions); @endphp {{ $modulePerms->take(2)->implode(', ') }} @if($modulePerms->count() > 2) ... ({{ $modulePerms->count() }} total) @endif @else No modules assigned @endif | @if(!empty($role->setting_group_access_summary)) @php $settingGroupPerms = collect($role->setting_group_access_summary); @endphp {{ $settingGroupPerms->take(2)->implode(', ') }} @if($settingGroupPerms->count() > 2) ... ({{ $settingGroupPerms->count() }} total) @endif @else No setting groups @endif | {{ $role->show_on_registration ? 'Yes' : 'No' }} | Edit @if(!in_array($role->name, ['super_admin', 'admin', 'user'])) {{-- Prevent deleting core roles --}} @endif |