We want to hide transition's from parent issue and we have A script that will update the status of parent issue automatically when sub-tasks is hiding .
I have tried some default conditions to particular admin group to transition on parent issue but that post-function script in sub-task is failing to transition automatically.
Could anyone help us to achieve this task
Supposing your parent issue needs to change from status "A" to status "B" when the subtask changes to "hidden" status, you can try a rule :
In your project parameters -> project automation -> project rules, and then :
- WHEN : demand transition
- IF : JQL query corresponds to (for example issueType = "subtask")
- RELATED REQUEST : parent (select your link type)
° IF : JQL condition (for example status != "B")
° AND : condition of related requests (status = "hidden"
° SO : transition to the correct status
Note that " - " is for the master branch, and " ° " for the secondary branch
Hi @Mahesh Kallepalli ,
I did not exactly understand what you want to achieve, but you can use this code to transition the parent issue from the subtask :
def parentIssue = issue.getParentObject()
def userKey = "user_that_triggers_the_transition"
def transitionId = 41
WorkflowTransitionUtil workflowTransitionUtil = ( WorkflowTransitionUtil ) JiraUtils.loadComponent( WorkflowTransitionUtilImpl.class );
I have achieved that when sub task is transitioned parent issue status is changing every time transitions will happen from sub task only we don't want to allow any user or agent to transition from main task so we are thinking to hide the transitions from parent task.
You could use a validator in the parent workflow transition (the users will still see the button, but will get an error message if they click it) :
InvalidInputException userErrorMsg= new InvalidInputException()
String errorMsg = "You cannot trigger this transition on the parent issue."
Let me know if that helped.
It’s very important to have access to the workflow process from anywhere. Especially if you manage the work of others. There is no difference whether you’re out of office, or drive a ca...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event