I would like to write a script with Script runner that updates the text boxes based on drop-down values.
The drop down has three values - default, X and Y. when the user selects default, no field should be displayed. When the user selects X, the text box corresponding to X should be displayed. Similarly when the user selects Y, the text box corresponding Y should be displayed.
The change should happen before the issue is created. Is there a way to select the fields dynamically..?
Finally got the solution by adding a behaviour on field level and added a server side script.
def CField1= getFieldByName("Field Name 1")
def CField2= getFieldByName("Field Name 2")
def TCType = getFieldById(getFieldChanged())
def selectedOption = TCType .getValue() as String
if(selectedOption=="Status")
{
CField1.setHidden(false)
CField2.setHidden(true)
}
else if (selectedOption=="Results")
{
CField1.setHidden(true)
CField2.setHidden(false)
}
else if (selectedOption==null)
{
CField1.setHidden(true)
CField2.setHidden(true)
}
Hi all
Anyone know how I can just get a script that will create a text box when I select "Other" from my dropdown list?
Really need help here?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.