How do you add custom field of assignee's email address?

Jaesang Kim May 30, 2019

Hi all, 

I'd like to add a custom field of assignee's email on the issue filter result list. 

Is there any way to achieve it? I looked at the plugin "Script Runner" to see if it would have a function to make it work. 

Any suggestion would be appreciated.

Thank you in advance.

Jaesang 

1 answer

1 accepted

0 votes
Answer accepted
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.
May 30, 2019

ScriptRunner can do it.  

Add a "scripted field" called something like "assignee email" (you don't have to put this on the issue screen to get this to work)

For the script, you need to read the assignee, get their email from the directory and return it.  As plain text, this would be something like

return issue.getAssignee().getEmailAddress()

(This is from memory, you might want to check the API docs.  And possible get a bit more clever with formatting, such as returning html, and using a mailto: prefix so the address can come out as a link)

 

Please bear in mind a lot of people don't want this exposed, and make sure you never plan to put your Jira out on the internet, as the addresses will be added to spam lists.

Jaesang Kim May 31, 2019

Thanks a lot Nick for your answer, I'll try it. 8)

Suggest an answer

Log in or Sign up to answer