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

how to display a script field in the create and edit screen

Tomas Arguinzones Yahoo April 28, 2017

Hi...I have been reading that this is a limitation in scriptrunner that script fields are not displayed neither in edit nor create screens but I have also read that there are some workarounds but I have not found them. And I understand the reason why script fields dont show in those screens but there are situations where they should be displayed. For instance, I have a script field to show the Epic ID if a Story is associated to a Epic. The scripts works in the view screen of the Story and Issue Navigavor (the epic ID is being properly displayed). However, I would also like that when the user is creating the Story and select an Epic Link to link to it, that the Epic ID of the selected epic be displayed. Similarly, I would like that when the Story is being edited, if the user changes the Epic Link, the Epic ID of the new epic link selected be displayed. Is there a way to accomplish that? I am on the latest version of JIRA 7.3.4, and the latest version of scriptrunner 5.0.1

Thank you in advance!

1 answer

Suggest an answer

Log in or Sign up to answer
2 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 28, 2017

Scripted fields only have a "view" template, because users can't put data in them.  This tells JIRA that there is nothing to show on screens which need input.

There is no way to get them to appear on screens that allow for updates.

Graham Twine
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.
February 17, 2023

Hello @Nic Brough -Adaptavist- is this still the case in 2023?

 

If so is there a way to create a 'custom field' that accepts input using scriptrunner, or do I need to create this in my own plugin?

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
February 17, 2023

Yes, the whole point of scripted fields is that they are calculated, not entered.

There is no way to create a custom scripted-field that accepts input, the raison d'etre for each is a direct contradiction.

Add a normal enterable custom field, and then script a calculated field based on that.

Like Graham Twine likes this
Graham Twine
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.
February 18, 2023

thanks for the prompt response, much appreciated!

BURMA RAJASHEKAR February 22, 2023

Hi Nic Brough, I have a scripted field which gets a value calculated based on the other fields. I have removed all the values from the other fields so now i wanted to edit the scriptted field also but am not able to do it. Please let me know how can i be able to edit the scriptted field ??

TAGS
AUG Leaders

Atlassian Community Events