@extends('backend.layouts.app') @section('title', __('labels.backend.access.roles.management') . ' | ' . __('labels.backend.access.roles.create')) @section('content') {{ html()->form('POST', route('admin.auth.role.store'))->class('form-horizontal')->open() }}

@lang('labels.backend.access.roles.management') @lang('labels.backend.access.roles.create')


{{ html()->label(__('validation.attributes.backend.access.roles.name')) ->class('col-md-2 form-control-label') ->for('name') }}
{{ html()->text('name') ->class('form-control') ->placeholder(__('validation.attributes.backend.access.roles.name')) ->attribute('maxlength', 191) ->required() ->autofocus() }}
{{ html()->label(__('validation.attributes.backend.access.roles.associated_permissions')) ->class('col-md-2 form-control-label') ->for('permissions') }}
@if($permissions->count()) @foreach($permissions as $permission)
{{ html()->label( html()->checkbox('permissions[]', old('permissions') && in_array($permission->name, old('permissions')) ? true : false, $permission->name) ->class('switch-input') ->id('permission-'.$permission->id) . '') ->class('switch switch-label switch-pill switch-primary mr-2') ->for('permission-'.$permission->id) }} {{ html()->label(ucwords($permission->name))->for('permission-'.$permission->id) }}
@endforeach @endif
{{ html()->form()->close() }} @endsection