@include('admin.Master.header') {{ trans('admin.roles.create') }} @csrf Name {!! Form::text('name', null, ['placeholder' => 'Name', 'class' => 'form-control']) !!} @error('name') {{ $message }} @enderror @php $i = 0; @endphp @foreach ($permission as $groupName) {{ $groupName->main_group }} @php $permissions = Spatie\Permission\Models\Permission::select('id', 'display_name') ->where('main_group', $groupName->main_group) ->get(); @endphp {{-- @if ($groupName->main_group == 'Role' || $groupName->main_group == 'User') All @endif --}} @foreach ($permissions as $per) id, old('permission'))) || ($groupName->main_group == 'Dashboard')) checked readonly @endif> {{ $per->display_name }} @endforeach @php $i++; @endphp @endforeach @error('permission') {{ $message }} @enderror {{ trans('admin.buttons.save') }} {{ trans('admin.buttons.cancel') }} @include('admin.Master.footer')
{{ $message }}