lib/rally_user_helper.rb
def create_workspace_permission(user, workspace, permission)
      # Keep backward compatibility of our old permission names
      if permission == VIEWER || permission == EDITOR
        permission = USER
      end

      if permission != NOACCESS
        new_permission_obj = {}
        new_permission_obj["Workspace"] = workspace["_ref"]
        new_permission_obj["User"] = user._ref
        new_permission_obj["Role"] = permission

        if @create_flag then new_permission = @rally.create(:workspacepermission, new_permission_obj) end
      end
    end
# Create Admin, User, or Viewer permissions for a Workspace
Create Admin, User, or Viewer permissions for a Workspace
Create Admin User or Viewer permissions for a Workspace
def create_workspace_permission(user, workspace, permission)
      if permission == VIEWER || permission == EDITOR
        permission = USER
      end
      if permission != NOACCESS
        new_permission_obj = {}
        new_permission_obj["Workspace"] = workspace["_ref"]
        new_permission_obj["User"] = user._ref
        new_permission_obj["Role"] = permission
        if @create_flag then new_permission = @rally.create(:workspacepermission, new_permission_obj) end
      end
    end
def create_workspace_permission ( user , workspace , permission ) if permission == VIEWER || permission == EDITOR permission = USER end if permission != NOACCESS new_permission_obj = { } new_permission_obj [ "Workspace" ] = workspace [ "_ref" ] new_permission_obj [ "User" ] = user . _ref new_permission_obj [ "Role" ] = permission if @create_flag then new_permission = @rally . create ( :workspacepermission , new_permission_obj ) end end end
Create Admin, User, or Viewer permissions for a Workspace
Create Admin User or Viewer permissions for a Workspace
# Keep backward compatibility of our old permission names
user
workspace
permission