Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Custome Field A change Custome Field B

amitde
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!
January 18, 2022

Hey all, 

I'm trying to do the following - 

def selectedOption = issue.get("customfield_26136", "None")

switch (selectedOption){
case 'Penetration Testing':
issue.setDescription("I am a pentest");
break;
case 'Threat Model':
issue.setDescription("I am a threat model");
break;
case 'Code Review':
issue.setDescription("I am a code review");
break;
case 'Design Review':
issue.setDescription("I am a design review");
break;
case 'Other':
issue.setDescription("I am a other");
break;
case 'None':
issue.setDescription("Activity Type Was Not Chosen.");
break;
}

return selectedOption

In the hopes to change the description based on the security activity type that our users are choosing. 

For some reason it's not changing the description while editing nor while seeing the issue. 

I also want to listen to events of the custom field 'security activity type' being changed and change the description accordingly. 

 

What am i doing wrong? 

Thanks in advance for the help, 

1 answer

0 votes
amitde
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!
January 19, 2022

Managed to do this with - behaviour scripts. if anyone else is intreseted: 

here

Suggest an answer

Log in or Sign up to answer