1

我正在尝试编写一个小型 Rails 应用程序,该应用程序将使用 Jira4R gem 与 Jira 交互。但是,虽然我在创建问题时没有问题,但在将自定义字段附加到问题时遇到了真正的麻烦。

关于我将如何做到这一点的任何想法?

目前我正在创建这样的问题:

issue = Jira4R::V2::RemoteIssue.new
issue.project = "TEST"
issue.summary = params[:issue][:summary]
issue.description = params[:issue][:description]
issue.type = 6
issue = @jira.createIssue(issue)
4

1 回答 1

4
   issue = Jira4R::V2::RemoteIssue.new
   issue.project = "TEST"
   issue.summary = params[:issue][:summary]
   issue.description = params[:issue][:description]
   issue.type = 6

   c = Jira4R::V2::RemoteCustomFieldValue.new
   c.customfieldId = "customfield_10000"
   c.values = current_user.full_name

   issue.customFieldValues = [c]
   issue = @jira.createIssue(issue)
于 2009-10-20T11:55:04.990 回答