Custom Field Values can't be updated through Remote Calls

XMLWordPrintable

    • Type: Bug
    • Resolution: Answered
    • Priority: Medium
    • 5.0
    • Affects Version/s: 4.2.2
    • Component/s: None
    • 4.02

      Im trying to update the value for some custom fields but through remote API seems to be impossible.

      Tried with XML-RPC and SOAP, both don't update the values.

      My field has the id: 10072 and 10073 so I've used the follow:

      // SOAP by JAVA

      Collection<RemoteFieldValue> values = new ArrayList<RemoteFieldValue>();
      values.add(new RemoteFieldValue("summary", new String[]

      {"[UPDATED] SOAP TEST"}

      ));
      values.add(new RemoteFieldValue("customfield_10072", new String[]

      {"0"}

      ));
      values.add(new RemoteFieldValue("customfield_10073", new String[]

      {"03/01/2011 16:00:00"}

      ));
      service.updateIssue(token, "ISSUE-KEY", values.toArray(new RemoteFieldValue[]{}));

      // XML-RPC by GROOVY
      def rpc = new XMLRPCServerProxy(baseJiraUrl, true)
      def loginToken = rpc.jira1.login('user', 'pass')

      def values = new HashMap()
      values["summary"] = ["Test XMLRPC"]

      values["customFieldValues"] = [
      [values:[0], customfieldId:"customfield_10072"],
      [values:["01/01/2011 00:00:00"], customfieldId:"customfield_10073"],
      ]

      rpc.jira1.updateIssue(loginToken, "FDE-5641", values)

      // END

      I would like to say that there's no decent documentation about how to update custom field values. In SOAP you have the STUB so you've got a method to accomplish that. In XML-RPC I've used some python code but changed to the way the ISSUE is returned, so I just made an copy of the struct returned by getIssue to create the updateIssue one, still doesn't work even though with tons of tests.

      It's seems the server is not able to update those values, it just ignore them. May anyone give me hints? It's really a bug or Am I doing something pretty bad?

      Thanks in advance.

              Assignee:
              Unassigned
              Reporter:
              casmeiron
              Votes:
              2 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: