JIRA - Add watchers to issue based on field value

Hi all,

I have been searching the forum for a similar problem but couldn't find anything that seemed to match what I am trying to do here. Any help appreciated... Note that I am running an evaluation licence of JIRA running on our local servers.

1 transition in my workflow is to assign a number of persons who as a team will be responsible for resolving this issue. When I say "assign" I do not mean the default Jira assign function. In my case, I have a screen with 3 different user pickers.

Current behaviour: When the 3 persons are selected and I save the modification, the change is saved properly and is visible. However right now none of the 3 users is informed about this.

Requested behaviour: Upon saving, I would like the 3 selected users to be informed about this assignment and would like them to be set as "watchers" of this issue in order for them to be notified about updates.

What are my options to achieve this?

Thanks in advance for your help!

1 answer

1 vote

Because you aren't using the assignee field, Jira doesn't know about these assignees.

I think your best approach might be quite simple - go to your notification scheme and for the event "update", add three lines. The option to use is the "user custom field value", and you need to select each one of the three fields separately.

This will cause emails to go out to the named users, and you should do it for all the events you want them to get notified for.

Watching is a bit different - if you want to work with watchers, you're going to need a bit of scripting or code to copy the users out of those three fields and into "watchers" (and then I'd skip the notification trick above, as they'll already be watching)

Thanks Nic, for taking the time to answer - definitely a good start.

Where is the scripting done in JIRA? From the bit of research I just did it seems a separate plugin is required.

Are there any good resources out there you could recommend?

Correct - there's no scripting as such built into Jira. There are a couple of add-ons which provide scripting facilities, the oldest one being Jamie Echlin's "script runner". I've not really used the others in anger, the script-runner does everything I've needed, so I can't recommend any others over it.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Jan 08, 2019 in Jira

How to Jira for designers

I’m a designer on the Jira team. For a long time, I’ve fielded questions from other designers about how they should be using Jira Software with their design team. I’ve also heard feedback from other ...

918 views 3 9
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you