@foreach($permissionGroupTypeList as $key => $permissionGroupType)
{{$permissionGroupType->name}} Permissions
@foreach($permissionGroupType->permissionGroups as $key=>$value)
@php
$collectionArray = $value->getPermission->pluck('id')->toArray();
$checkAll = '';
if(count($role_permission) > 0){
$diff = array_diff($collectionArray, $role_permission);
if (empty($diff)) {
$checkAll = 'checked';
}
}
@endphp
@endforeach
@endforeach