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

Display field values based on selection if another field value

Vinay Humility July 18, 2024

Hi All,

i have 2 custom fields in my portal form jira cloud

Field1 - 1,2,3 values

Field2 - 4,5,6,7 values

when customer selects option 1 in Field1 then customer should only see 4,5 as options in Field2

 

i tried using Jira Cloud Script Runner using behaviours. But unfortunately its not working for me. 

2 answers

0 votes
Kevin Patterson
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.
July 18, 2024

Hi  @Vinay Humility ,

If you are a JSM premium customer you could use Assets to accomplish this. I have an assets schema that has a few object types that I use for the sole purpose of driving dynamic field behaviors like you mentioned above. In your example your schema would look something like this: 

2024-07-18_10-59-56.png

You can then create custom fields of the asset type. custom Field 1 should be configured to show all objects from the field 1 object type. custom Filed 2 should be configured to show only objects that have a reference to the object in from the selection in custom field 1 using the filter issue scope AQL. The tricky part can be the filter issue scope. on your second custom field you will want to add a filter issue scope that will look at the custom field containing values 1,2,3 and lookup the inbound references, I've copied a screenshot below that shows how this would look below. let us know if you have any questions on this approach.

filterissue.png

here is the end result. selecting value 1 in example dynamic field 1 limits the values in example dynamic field 2 to only showing 4,5.

results.png

 

 

Bhanu Prakash
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!
July 20, 2024

@Kevin Patterson  Thanks for your response.

Apologies, but we are small company recently started using JIRA Cloud. Not using the Premium for not atleast. WOrking on Standard plan itself.

 

Is there any other way works in Jira Cloud standard plan

Kevin Patterson
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.
July 22, 2024

Not natively, at least not that I have found yet. If you have low user count it might be worth investigating the Atlassian Marketplace for an application that provides Dynamic field capabilities, this could a more cost effective alternative than upgrading to JSM Premium.

sharos_pillai September 16, 2024

Hi @Kevin Patterson , I want to setup something similar using Assets.

In the drop-down list, there are 4 options.

When a user selects Option 4 from the drop down, I want to show a new custom field (movement type) on the request form.

When users select Option 1 to 3, this custom field is not shown.

Does the above method work?

Thanks

SP

 

0 votes
Nicolas Grossi
Banned
July 18, 2024
Vinay Humility July 18, 2024

Thanks @Nicolas Grossi  for the response

i have reviewed the link

I am aware that it can be achievable with Script Runner Using Behaviour Script. But the link you shared was about jira data center and I am using jira cloud. 
also i got to know that behaviour in jira cloud uses only JS code, if we are trying to write groovy its not allowing to save the code..

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events