Versions Compared

Key

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

This article explains how to block creation of sub-tasks if the subtasks are already existing in the parent issue has existing sub-tasks using the Create on Transition app.

Instructions

  1. Add a post-function to the intended transition , to create a sub-task.
    To add a post-function, navigate to Cogwheel > Cog wheel (Image Added) > Issues > Workflows > select , select the workflow of the project, and edit the same.
  2. Select Select the Create Sub-task post function as shown below:
    Image RemovedImage Added
  3. Select the Conditions & Configuration and add , add %jql_result_count% in Condition 1 and Regular expression pattern value as "0" by marking the in Regular expression pattern, and select the Exact field under Conditions section:
    Image Removed
    By using the %jql_result_count% and Regular expression pattern value as "0", it checks Use the condition and regular expression values to check for the JQL query available under the Configuration section.
    Image Added
  4. Add the value parent = %original_key% under the Configuration section in the JQL query.
    Image Removed
    It checks  It checks whether the parent issue has sub-task(s) for the specific transition and creates a new sub-task(s) accordingly.
    Image Added
  5. Click Update to save the settings. Verify the condition:
    Image RemovedImage Added
  6. Publish the workflow draft.
  7. Perform the In Progress transition as shown. You will notice . Note that issues are created based on the condition . If and if the transition repeatsis repeated, it will does not create any duplicate sub-tasks.
    Image RemovedImage Added
Info

It is recommended to try the provided solution in a non-production environment and ensure everything is working as expected, before trying in a production environment.