public function setPermissions(PermissionsInterface $permissions)
    {
        // Assure the user has always all rights.
        if ($this->user) {
            $permissions->grant($this->user, Permissions::PERMISSION_ALL);
        }
        $this->permissions = $permissions;

        return $this;
    }
public function setPermissions(PermissionsInterface $permissions)
    {
        // Assure the user has always all rights.
        if ($this->user) {
            $permissions->grant($this->user, Permissions::PERMISSION_ALL);
        }
        $this->permissions = $permissions;

        return $this;
    }
public function setPermissions ( PermissionsInterface $ permissions ) { // Assure the user has always all rights. if ( $ this -> user ) { $ permissions -> grant ( $ this -> user , Permissions :: PERMISSION_ALL ) ; } $ this -> permissions = $ permissions ; return $ this ; }
Sets the Permissions of an Organization

@param PermissionsInterface $permissions

@return $this
Sets the Permissions of an Organization