Skip to content
This repository has been archived by the owner on Jul 30, 2020. It is now read-only.

JIRA::Project#soapify_for_msg lacks permissionScheme part of the message #21

Open
paulvt opened this issue Nov 22, 2013 · 0 comments
Open

Comments

@paulvt
Copy link

paulvt commented Nov 22, 2013

As the SOAP interface seems to be the only way to create a project via any API with JIRA, I'm trying to do this with jiraSOAP. However, it turned out that the projects I created had no permission scheme which leads to null-pointer errors in JIRA itself.

When I found out that in all examples at least a permission scheme needs to be set (other schemes seems to have sane defaults), I also found out that jiraSOAP doesn't add a permission scheme with it's set ID to the message, hence, no viable projects can be created. I fixed it by adding the following to lib/jiraSOAP/entities/project.rb:

class JIRA::Project < JIRA::DescribedEntity
  ...

  def soapify_for msg
    ...

    msg.add 'permissionScheme' do |submsg|
      submsg.add 'id', @permission_scheme.id
    end if @permission_scheme
  end
end
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant