Forums

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

Do not display accountid in Comment if issue is Unassigned

Kasturee
Contributor
April 21, 2022

Hi

I am trying to write an automation rule that adds a comment to an issue if the Treatment field has more than one option selected. The comment must @mention the Assignee and Reporter.

If the issue is assigned to a user, it works perfectly but if the issue is unassigned then I get the attached error. I do not want the accountid to be displayed in the Comment if the issue is unassigned. Does anyone know where I am going wrong in my automation rule?image.png

image.pngimage.png

3 answers

0 votes
Kasturee
Contributor
April 22, 2022

I rewrote the automation rule and split up the actions based on each of the conditions, and it now works.

0 votes
Kasturee
Contributor
April 21, 2022

Thanks @Bill Sheboy  for your suggestion. I tried it out with and without an Assignee and unfortunately without the Assignee still displays the accountId. I have attached a screenshot of both scenarios

image.png

Bill Sheboy
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 22, 2022

This seems to indicate the assignee is blank versus null, which I thought was fixed so both could evaluate to EMPTY with the REST API and JQL queries.

I recommend working with your site admin to submit a support ticket for this to have Atlassian take a look: https://support.atlassian.com/contact/#/

Kasturee
Contributor
April 24, 2022

Thanks Bill. Will do so

0 votes
Bill Sheboy
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 21, 2022

Hi @Kasturee 

It seems there are some missing curly brackets for that format of the conditional logic.  Or if the assignee previously had a value and it is no longer evaluating to null.

Perhaps try one of the other forms of "if":

{{#if(not(issue.assignee.isEmpty))}}[~accountId:{{issue.assignee.accountId}}]{{/}}

Kind regards,
Bill

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events