@extends('layouts.app') @section('form-title') {{ __('Add role') }} @endsection @section('breadcrumb') @endsection @section('content')
@csrf @include('authorities.buttons')
@if($errors->has('name'))

{{ $errors->first('name') }}

@endif
{{--
{{ __('Permissions') }}
@foreach($authorizations as $section => $permissions)
  • {{ ucfirst(__($section)) }}
  • @foreach($permissions as $permission)
    @endforeach
@endforeach
--}} @foreach($authorizations as $parent_section => $sections) @php if(! isModuleEnabledForSection($parent_section)){ continue; } @endphp
{{ ucfirst(__($parent_section)) }}
@foreach($sections as $section => $permissions) @php if(! isModuleEnabledForSection($section)){ continue; } @endphp
  • {{ ucfirst(__($section)) }}
  • @foreach($permissions as $permission) @php $slug = Illuminate\Support\Str::slug($permission->name); @endphp @if(!$permission->is_super_admin_only)
    {{ ucfirst(__($permission->name)) }}
    @if($slug === 'create-project-using-wizard')
    This permission requires the following to be enabled first: Add project, Add tasks of own organization, Add end users and Send system message
    @endif
    @elseif(getAuthUser()->isSuperAdmin())
    {{ ucfirst(__($permission->name)) }}
    This action is restricted to {{ __('Super admin') }}
    @endif @endforeach
@endforeach
@endforeach @include('authorities.buttons')
@endsection @push('child-scripts') @endpush