Why is this parent transition post function not working?

Miles Tillinger January 20, 2015

I have this fairly straightforward workflow post-function that should close a parent issue once all of its sub-tasks have been closed.  But it doesn't sad Any suggestions?

View_Workflow_—_The_Suits_workflow_-_hailo_jira_com3.png

Transition__Close_-_hailo_jira_com1.png

Transition__Close_-_hailo_jira_com2.png

_HFB-1093__Test_by_miles_-_hailo_jira_com4.png

3 answers

0 votes
Licensing AVL July 20, 2016

I have the same problem. Does anyone of you have a solution for this?

Kind Regards

Elke

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 20, 2016

It's the same answer - check the conditions

Gianni Pucciani August 15, 2016

I had the same issue. The problem was on the condition of the parent transition to hide the transition to the users. Removing that one the post function works correctly. And the transition condition on the children subtasks does the job of hiding the transition at the same time.

0 votes
Philippe Aubin
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.
April 21, 2015

I Have the same problem, with the only difference that my parent does not transtion because (i think) it has 3 scripted post functions ( 1 creating a subtask, 1 sending a mail and the last one setting a custom field). 

When i remove those post function the transition works.

What do you guys thiknk ?

0 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 20, 2015

Do you have any conditions or validators on the "close" transition?

Miles Tillinger January 20, 2015

The second image is the Conditions tab, and there's no Validators. My current hypothesis is that it is because of the Resolution field being required in the Screen for the Close transition. Also, the post-function does work if dragging tickets into columns in the Work view. However, it doesn't work if I Close all the sub-tasks from the parent ticket view (see image #4 in the original post).

Miles Tillinger January 20, 2015

> The second image is the Conditions tab, which you can see has 1 condition, but it won't block the Close transition if all sub-tasks are closed.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 20, 2015

Resolution is not required on the transition - only the validators do that and you've said you have none. You could have a point though - could you try adding a post-function to the *parent* workflow of "set resolution to fixed" (temporary, of course) and see if it works then? Also, does the person closing the sub-task have the permission to close the parent as well?

Miles Tillinger January 20, 2015

Cheers Nick. I tried setting the resolution, and that post function works ok. But transitioning the parent ticket still doesn't work as expected! That said, it _is_ working on the Work view of the Agile board ie. when I close the last sub-task, I get a dialog asking if I want to close the parent ticket as well. But it still doesn't work in the ticket view, which is frustrating because as some of the team use that view more often.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 20, 2015

Ah, actually, I've just realised it isn't. Agile adds a function that does the automatic close, so I suspect yours is not working at all! The workflow you've given in the screenshot looks fine, but can I just ask if it is the only workflow for the project? If it is not, then what issue types is it used for?

Miles Tillinger January 20, 2015

Indeed, it is the only workflow for the project.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 21, 2015

Hmm, well, it all looks to be set up correctly, so the next question is if your user executing the sub-task change also *could* close the parent if they look at it in standard Jira view?

Miles Tillinger January 21, 2015

of course they *could* ;-) it's not the end of the world, just frustrating as an engineer when something that seemingly should *just work*, doesn't ... and I have no way to debug it >:-|

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 21, 2015

No, I'm sorry, I did not phrase that correctly. I wanted you to check the permissions on the top level issue. Look at one which has open sub-tasks and check that they are NOT offered "close" as a transition. Then look at another that has all it's subtasks closed - can they transition it manually?

Suggest an answer

Log in or Sign up to answer