Execute the function before the transition

Denis Shestov
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.
November 3, 2017

Hi all! 

Please help me with my case:

(comment: i have add-ons JSU)

I want to be able to change the assignee, but (!) if assignee has been changed - i need to get the value of the field of the current assignee. 

What i tried to do:

i create 2 transitions.

https://yadi.sk/i/MS2RiGcn3PNX7M

In first transition, i make a post-function that copies the value current assignee to custom field (his name: "First assignee" )

https://yadi.sk/i/kSJntfgA3PNXN8

In second transition i wanted to open screen ( https://yadi.sk/i/c_wffzl33PNY9a ), where have field Assignee (for change assignee), but screen not opened.

https://yadi.sk/i/Ou_7BfSr3PNXzk

How can i implement?

maybe create another ("new assignee") custom field? 

Steps: 

1. on screen in transition: custom field, for to word new assignee

post function:

2. copy current assignee to custom field "First assignee"

3. copy custom field "new assignee" - to current assignee

m?

Thanks for all = )

2 answers

1 accepted

0 votes
Answer accepted
Denis Shestov
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.
November 15, 2017

I could realize this function with help addon: 

Jira Misc Workflow Extensions

Postfunction name: 

Copy value from field to field (JMWE add-on)Copy the value(s) of one field to another field. Can copy the value of the field before it was changed on the transition's screen.
0 votes
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.
November 3, 2017

Hello,

To be honest I do not quite understand what you want to accomplish.  What do you mean by current assignee? If assignee has been changed then the current assigne equals to assignee. Or you want to save somwhere previous assignee?

Denis Shestov
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.
November 3, 2017

I want to be able to change assignee and after changing in the Custom field Primary assignee field the value of who was before the change appeared.
I apologize for the English. my assistant is Google translator :)

Suggest an answer

Log in or Sign up to answer