JEMH notification condition

Hello,

I am new in JEMH, but I created profile with template set and event listener. I have even simple macro in template set for sending notification by condition: 

#if($issue.getCustomFieldValue("customfield_11201")=="AU")

$jemhUtils.setInhibitSending(true) 

#end

It works quite well, but it inhibit all notifications. I am curious if there is any possibility to set condition, where it will be inhibit only for reporter for example.

Maybe it is trivial or wrong question or not possible for JEMH, but I have no idea and don't know where to find the answer.

Can someone help please?

Thank you,

Filip

 

1 answer

Hi Filip,

If the user receiving the email notification is a JIRA user, their user will be present in $recipientUser within the template context.

Therefore to inhibit notifications for the recipient of the email, if they are both a JIRA user and the issue reporter, you could do the following:

#if($issue.reporter.equals($recipientUser))
$jemhUtils.setInhibitSending(true)
$jemhUtils.setInhibitSendingReason("Notifications for the reporter are blocked!")
#end

If you need any further help with this, please create an issue via our JIRA instance: The Plugin People - JIRA 

Kind Regards,

Reece  @ The Plugin People

Hi Reece,

Thank you very much for respond. I wanted create issue via your JIRA instance, but I can't connect there.

It looks very interesting, is there any chance to inhibit all non jira users? Or is there any tutorial for working with scripts?

I am sorry for more questions and your time. I know it is quite banal topic.

 

Thank you,

Filip

Hi Filip,

You should be able to sign up for an account via our JIRA instance and then create issues in the Support project.

JEMH's Event Listener is scriptable, in a similar way to using notification inhibition within email templates. You can configure  filter scripts per project in the event listener (for both JIRA users and non-JIRA users). The following wiki page contains a brief overview: JEMH Event Listener Filter Scripts

This community is not the place to discuss your specific JEMH configuration, please contact us directly either via JIRA or via email: support@thepluginpeople.com

Kind Regards,

Reece

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published yesterday in Jira

5 ways you can make the most of Jira Software and Bitbucket Cloud

As part of the Bitbucket product team I'm always interested in better understanding what kind of impact the use of our tools have on the way you work. In a recent study we conducted of software devel...

58 views 0 5
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