When changing the status 'In Progress' to 'Resolved' I have created a specific screen. In this screen we can leave a comment to the customer. This in most cases will be a overview of what we have done and what the specific solution is to their problem.
We would like this comment to be entered automatically in a specific custom field named 'Solution'.
Right now, I tried this set up, but it is obviously not working as I feel there are some things missing. I couldn't find how to specify the exact transition screen.
Current set-up:
Thanks in advance!
Welcome to the community. Based on your ask and information, your automation rule should not be triggered off from issue commented event. It should be triggered off from issue transitioned from "In Progress" to "Resolved". Before you edit your issue action, conduct a "Refetch issue data" action, then you can obtain the latest comment via smart value {{issue.comments.last.body}}
captured into your custom field.
Here are some key references in regards to issue comments (since an issue can have many comments) and how to use smart value syntax -
https://support.atlassian.com/cloud-automation/docs/jira-smart-values-issues/#--issue.comments--
***** To obtain the latest issue comments using rule: {{issue.comments.last.body}}
which accesses the body of the last comment added to an issue, In addition, you can also access the author of the last comment using {{issue.comments.last.author.displayName}}
Hope this also helps.
Best, Joseph Chung Yin
Hi, I first tried it without the 're-fetch issue data' and it worked.
But where should I put the 're-fetch issue data' action? Because I cannot add it as the first action of the automation.
Also, what is the specific reason for this action in this automation?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I believe you may got confused with Triggering event and action. "Re-fetch issue data" is an action which is always available after a triggering event.
The reason for using issue transitioned as a triggering event is because your original ask where you stated - "When changing the status 'In Progress' to 'Resolved' I have created a specific screen. In this screen we can leave a comment to the customer. This in most cases will be a overview of what we have done and what the specific solution is to their problem. ".
It simply means that the rule will be triggered when an issue is transitioned.
In addition, you can also add an advance field comparison condition (example - "
to check if a comment is an internal or shared by using the smart value {{comment.internal}} where value is either True/False.
This will help you to ensure only shared comment is used in your process.
Hope this helps.
Best, Joseph
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ah, I meant, what is the reason why I have to add the 'refetch the issue' action?
I understood why the transition event would be a better trigger than the 'made a comment' one.
I'll have a go with the conditional logic in the automation.
ETA: I now know why the 'refetch issue' action was added. That way it gets automatically refresh so you don't have to press the refresh in the browser.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Valerie Vliegen ,
Can you replace {{comment.body}} with {{issue.comments.last.body}} as the edit issue action and then check if it works?
Best,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi, I tried this and it worked! But, it also adds the last comment if it is an internal comment and that's not something that we would like.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.