Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 19:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

how can i get access to customfield values if it has more than one (like name, category, budget and so on)

Harald Pfitzner March 2, 2015

How can i get access to customfield values if it has more than one (like name, category, budget and so on).

If we use getCustomfieldValue(.....) only the internal database-key is shown.

We need it for Tempo Account values in another scripted field to show the values in seperate fields on an issue. 

May be they are attributes ore propertys instead of values but we need the access to it in scripted field. 

Best Regards

Harald Pfitzner

1 answer

1 vote
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 2, 2015

A custom field holding multiple values will return an array of options when queried.  You'll need to iterate over the array to get each one out individually

I'm not quite sure what you mean by "get access" though, or what you're trying to do.  And what are you using to generate your scripted field?

Harald Pfitzner March 2, 2015

Hi,

I'm new in grovvy or over scripting in jira.

To explain it in picture the data stored in an Tempo Account.

All data are columns in a single table in database except of the Category.

image2015-3-2 16:20:1.png

image2015-3-2 15:53:50.png

The funktion getCustomfieldValue(Account) shows an unique number as result, not the Key, not the Name and so on.

We need scripted fields they show us the stored information of Contact, Category, Monthly Budget in the issue.

The biggest problem i see is the Category stored in its own table.

Please can you show me how i can get it work. 

Best regards

Harald Pfitzner   

Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 2, 2015

Ah, right, that's a bit more painful. These are not customfields in the standard sense, they are fields tempo implements on Tempo accounts (standard customfields belong to JIRA issues). I don't know that you can get to them very easily - I think you need to invoke the Tempo API to read them, but I don't know how to do that

Harald Pfitzner March 2, 2015

Hi, Thanks for your quick response. I will contact Tempo to get the information we need. You can close this here. Best Regards Harald Pfitzner

Suggest an answer

Log in or Sign up to answer