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

How to copy create subtask via JMWE postfunction and set value

NewByatl
Contributor
August 16, 2023

How to copy create subtask via JMWE postfunction and set value in postFunction like this:

Customfield 10500, type singleselect

 

If (customfield_10500Of current task == M) {

then customfiled10500OfCreatedSubTask == S

}

else if (customfield_10500Of current task == L){

then customfiled10500OfCreatedSubTask == M

}

 

....

and ect.

 

Снимок экрана 2023-08-16 в 17.53.12.png

1 answer

1 accepted

0 votes
Answer accepted
David Fischer
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 16, 2023

Hi @NewByatl 

Can you share the full post function configuration? I'm having a hard time understanding what you're trying to achieve, and I'm particular why you're accessing sub tasks of the current issue...

NewByatl
Contributor
August 16, 2023

Sorry, I'm stupid. I no idea why a have done it.

 

Just fixed code like this and it's works!

 

if (issue.getAsString("customfield_10500")=="M"){
return "S"
}

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, ace, atlassian community event, donation, girls who code, women in tech, malala fund, plan international, kudos, community badge, badge, atlassian badge, International Women’s month, International Women’s Day, women's month, women's day

10 for Change at Atlassian Community Events

Show up and give back by attending an Atlassian Community Event: we’ll donate $10 for every event attendee in March!

Join an Atlassian Community Event!
AUG Leaders

Upcoming Jira Events