Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

change assignee of issue using post function to the value of a custom field.

Emily Fuller April 8, 2020

Hi, 

I have a custom field 'Product owner' which is a user picker(single field). 

I have a issue where i want to auto assign an Epic ticket to the user that is selected in the 'Product Owner' Field when going through a certain transition, I want to do this using a post function but i cannot work out how this is done. 

I do have a plugin of JMWE. Can someone please help me :)

Thanks 

2 answers

2 accepted

1 vote
Answer accepted
David Fischer
Community Champion
April 8, 2020

Note that you could also have used the Copy Value From Field To Field post-function to copy from the "Product Owner" field to the "Assignee" field. This would require zero scripting.

1 vote
Answer accepted
Radhika Vijji _Innovalog_
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 8, 2020

Hi Emily,

Sure. You need to add the Set field value post-function to the transition. Select the "Assignee" field. Input the value as:

{{ issue.fields["Product Owner"].accountId }}

Save the post-function and publish the workflow.

Regards,

Radhika

Emily Fuller April 8, 2020

thank you so much this has worked. I can use this throughout the workflow and its changed my life! very excited there was a solution to this! 

sujata birajdar June 9, 2021

In THis post function, iam not able to find any space to enter the above query . It gives only three option , to set it to :unassigned, automatic, to a specific user. 

 

how can i set Assignee field same as product owner field , i do not have any plugin installed though for the workflows.

Girish Ramakrishnan
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 24, 2021

hi Radhika, does your solution work only for JIRA cloud? I am not in JIRA cloud. What is the syntax we use for JIRA server in field value to set a custom field value to the assignee. I have a custom field that is a SQL+JQL text field. It returns a user account id. However i do not have a proper syntax to put into the field value of JSU in order to set this value to the Assignee field

In my below example you see the custom field name is "CodeReviewAssignee"

Pls help

Suggest an answer

Log in or Sign up to answer