Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Store display value of nFeed field (json data) into jira database

Bárbara Teruggi
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
April 10, 2017

Hi! I have issues when trying to record data from an option selected in an nFeed custom field. 

The nFeed field gets information from a REST WebService, which returns a Json object like this one: 

{"dataFromRest":[{"key":"option1","value":"1"},{"key":"option2","value":"2"},{"key":"Option3","value":"3"}

This is within the creation of a new Issue. When I'm processing the information of all customfields to save this data into jira database, I can only get the value from the selected option. 

mIssue.setCustomFieldValue(newCf, newCf.getValue(issue));

And this is how it goes all the way to textvalue from customfieldvalue table in jira's DB.

What I need to do is also save the 'key' part of the selected option which is the one I've used for displaying friendly information to the user, but I also need when Visualizing or Editing the Issue, in order not to call nFeed again. 

Is there any way I can store both parts of each option? 

Many thanks in advance for reading. I hope someone could help me. 

 

1 answer

0 votes
Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 8, 2017

Hi Bárbara! This looks like a developer question, so it would be better to post it at community.developer.atlassian.com. That's where our developer community hangs out :)

Cheers,

Ana

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events