ttt
ttt

Reputation: 4004

How to create dynamic field in Jira?

I want to create some dynamic field in Jira similar to what we do in JavaScript.

e.g. there is a dropdown list, with value a, b and c. If I select a, there will pop up some fields only for a; if I select b, there will pop up some fields only for b.

Can this be done in Jira, or are there any plugins that solve this problem?

Upvotes: 3

Views: 3765

Answers (1)

Kuf
Kuf

Reputation: 17828

You could use the JIRA Behaviours Plugin to change any field according to any selected field, for example:

FormField dropdown = getFieldByName("My Dropdown")
FormField other= getFieldByName("Other field")

if (dropdown.getFormValue() == 'A') {
 other.setHidden(false) // set custom filed vlaues
 other.setFormValue("A choosen")
} else {
 other.setHidden(true) // hide any fields you like
}

Upvotes: 3

Related Questions