{!! Form::customInput('text', 'name') !!}
@forelse($perms as $perm) @php $create= $read= $update=$delete=$print=false; foreach($perm as $p){ if($p->name=='create_'.$p->model) $create =$p; if($p->name=='read_'.$p->model) $read =$p; if($p->name=='update_'.$p->model) $update =$p; if($p->name=='delete_'.$p->model) $delete =$p; if($p->name=='print_'.$p->model) $print =$p; } $name=$p->model; @endphp @empty @endforelse
# @lang('create') @lang('read') @lang('update') @lang('delete') @lang('print')
{{ $name }} @if ($create) hasPermissionTo($create->name) ? 'checked' : '' }} value="{{ $create->id}}" /> @else - @endif @if ($read) hasPermissionTo($read->name) ? 'checked' : '' }} value="{{ $read->id}}" /> @else - @endif @if ($update) hasPermissionTo($update->name) ? 'checked' : '' }} value="{{ $update->id}}" /> @else - @endif @if ($delete) hasPermissionTo($delete->name) ? 'checked' : '' }} value="{{ $delete->id}}" /> @else - @endif @if ($print) hasPermissionTo($print->name) ? 'checked' : '' }} value="{{ $print->id}}" /> @else - @endif