Forums

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

How to write an Automation : If Reporter is the same as Approver transitioned to "Approved"

Leena Pratheepan
Contributor
March 27, 2024

Hello Community,

 

I need help for making an automation. I want that if an issue created and reporter and approver are the same person, then transition the issue to approved.

 

Thank you for your help in advance.

 

best regards,

 

Leena

2 answers

1 accepted

0 votes
Answer accepted
Tugba Capaci
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.
March 27, 2024

Hi @Leena Pratheepan 


A workflow like this will help you.

 Screenshot 2024-03-27 at 10.36.55.png

 

Tugba
actioner.com

Trudy Claspill
Community Champion
March 27, 2024

Hello @Tugba Capaci 

"key" is not a documented attribute of a user field, as per

https://support.atlassian.com/cloud-automation/docs/jira-smart-values-users/

Did you test this and find that it actually works?

Leena Pratheepan
Contributor
March 27, 2024

I will try it und will inform you. Thanks for your help

Tugba Capaci
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.
March 27, 2024

Hello @Trudy Claspill ,

I shared this workflow as a showcase for giving an opinion about the workflow basics.

Now, I tried to run this, and you're right, "key" is not necessary. I wrote it according to the placeholder on the "First value" field.



Screenshot 2024-03-27 at 11.04.34.png


Leena Pratheepan
Contributor
March 27, 2024

Hey @Trudy Claspill  @Tugba Capaci 

Thanks for your help. In create modus it does not work, so i change it.

tr.PNG

This configuration works for me.

issue.PNG

issue_2.PNG

Like Tugba Capaci likes this
Trudy Claspill
Community Champion
March 28, 2024

In the case where your Approvers field has multiple users and one of the users in that field matches the user in the Assignee field, then the condition will fail.

Screenshot 2024-03-28 at 12.12.53 AM.png

Like Leena Pratheepan likes this
1 vote
Trudy Claspill
Community Champion
March 27, 2024

Hello @Leena Pratheepan 

When is the Approver field set? Is it set in the Create Issue dialog or set at a later point after the issue creation has completed?

Have you tried to construct the rule? If so, show us what you have so far and tell us what part you are struggling to add.

Leena Pratheepan
Contributor
March 27, 2024

It`s set in the create issue dialog,

 

If Issue created -> reporter and approver the same person -> transition the issue to approved

 

the part reporter and approver are the same person is difficult to add. I do not know how?

Like Maria Elena Lovato likes this
Trudy Claspill
Community Champion
March 27, 2024

The general structure provided by @Tugba Capaci is correct, except for the Condition suggested.

You can use an Issue Fields Condition (1) to compare the value of one field to another field of the same field type.

Pick Reporter for one field (2).

By default the second part of the comparison will the set to Value. Click instead on Field (3).

Then you can select the Approver field (4). I don't have an Approver field so I specified another field.Screenshot 2024-03-27 at 7.31.05 AM.png

Leena Pratheepan
Contributor
March 27, 2024

@Trudy Claspill 

I had this solution but unfortunately I could not select Approvers. Approvers is Multi-User Customfield. Maybe that's why it didn't work.

Trudy Claspill
Community Champion
March 28, 2024

I think you are correct. It looks like if the first field you specify is a single user picker field (i.e. Assignee) then you can compare it only to other single user picker fields. Likewise if the first field you specify is a multiple user picker field (i.e. Approvers) then you can compare it only to other multiple user picker fields.

Like Leena Pratheepan likes this
Leena Pratheepan
Contributor
March 28, 2024

Yes, It`s right.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events