Forums

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

Unable to create subtasks using script runner

Swarna Radha
Contributor
July 26, 2018

Hi,

I am using the post function create subtasks (Script Runner). When i am adding conditions, an error message occurs during the transition "Workflow Invalid Action", if i add no conditions, it works.

In my case, i need to check that if a custom field (Single list)= A and Custom field (Multiple Select)= B, then it creates the sub tasks.

This is the condition: cfValues['Main System'] == 'Test2' && 'Test in cfValues['Impacted ']*.value

Please see screenshot for the error:

image.png

2 answers

1 accepted

0 votes
Answer accepted
Alexey Matveev
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 26, 2018

Hello,

Is this post function in the create transition step? If so, then make sure that this post function is last in the list of post functions.

Swarna Radha
Contributor
July 26, 2018

Hi, It is at last position of the post function.

0 votes
Mark Markov
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 26, 2018

Hello @Swarna Radha

If first field select list, condition should be like this

cfValues['Main System']?.value  == 'Test2' && 'Test' in cfValues['Impacted ']*.value
Swarna Radha
Contributor
July 26, 2018

Hi Mark,
It is working now )

Mark Markov
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 27, 2018

Glad to hear that! 

If it helps you, please mark answer as accepted. So that, other people will be able to find this answer easily for similar questions :)

Suggest an answer

Log in or Sign up to answer