public function hasRole($role_name)
    {

        if ($this->hasSuperUser())
            return true;

        foreach ($this->group->roles as $role)
            if ($role->title == $role_name)
                return true;

        return false;

    }