Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Table of Contents

...

For the sake of this exercise we will consider that all subtasks need to be closed in order to let an issue to be closed.

Add a new condition

Log in as an administrator and navigate to Administration-> Workflows and edit "Close" transition on the default JIRA workflow. Press `Add` a new condition:

Writing the SIL code

Code Block
// get all subtasks
string s_tasks=subtasks(key);

// process each subtask
for(string s in s_tasks)
// if subtasks' status is not closed the transition cannot be available and therefore return false 
  if(%s%.status != "Closed")
    return false;

// if not failed yet then the transition should be available
return true;