public function viewRoles()
    {
        $contenttypes = $this->getOption('contenttypes');
        $permissions = $this->app['permissions']->getContentTypePermissions();
        $effectivePermissions = [];
        foreach ($contenttypes as $contenttype) {
            foreach (array_keys($permissions) as $permission) {
                $effectivePermissions[$contenttype['slug']][$permission] =
                    $this->app['permissions']->getRolesByContentTypePermission($permission, $contenttype['slug']);
            }
        }
        $globalPermissions = $this->app['permissions']->getGlobalRoles();

        $context = [
            'effective_permissions' => $effectivePermissions,
            'global_permissions'    => $globalPermissions,
        ];

        return $this->render('@bolt/roles/roles.twig', $context);
    }
public function viewRoles()
    {
        $contenttypes = $this->getOption('contenttypes');
        $permissions = $this->app['permissions']->getContentTypePermissions();
        $effectivePermissions = [];
        foreach ($contenttypes as $contenttype) {
            foreach (array_keys($permissions) as $permission) {
                $effectivePermissions[$contenttype['slug']][$permission] =
                    $this->app['permissions']->getRolesByContentTypePermission($permission, $contenttype['slug']);
            }
        }
        $globalPermissions = $this->app['permissions']->getGlobalRoles();

        $context = [
            'effective_permissions' => $effectivePermissions,
            'global_permissions'    => $globalPermissions,
        ];

        return $this->render('@bolt/roles/roles.twig', $context);
    }
public function viewRoles ( ) { $ contenttypes = $ this -> getOption ( 'contenttypes' ) ; $ permissions = $ this -> app [ 'permissions' ] -> getContentTypePermissions ( ) ; $ effectivePermissions = [ ] ; foreach ( $ contenttypes as $ contenttype ) { foreach ( array_keys ( $ permissions ) as $ permission ) { $ effectivePermissions [ $ contenttype [ 'slug' ] ] [ $ permission ] = $ this -> app [ 'permissions' ] -> getRolesByContentTypePermission ( $ permission , $ contenttype [ 'slug' ] ) ; } } $ globalPermissions = $ this -> app [ 'permissions' ] -> getGlobalRoles ( ) ; $ context = [ 'effective_permissions' => $ effectivePermissions , 'global_permissions' => $ globalPermissions , ] ; return $ this -> render ( '@bolt/roles/roles.twig' , $ context ) ; }
Route to view the configured user roles.

@return \Bolt\Response\TemplateResponse
Route to view the configured user roles .