Forums

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

Jira Automation - Create Sub-Task and add a comment

Krzysztof Kiser
Contributor
August 14, 2020

Hi,

I am using Jira Automation in my instance and have a monthly scheduled sub-task create.

When the sub task is created, I want the automation to add a comment to the newly created sub task.

How can I accomplish this?


I tried with another For clause, but it doesn't seem to pick up that a sub task has just been created and returns an error that no issue had been created by my rule.

 

Here's my current state of the rule:

Screen Shot 2020-08-14 at 9.37.11 PM.png

1 answer

1 accepted

0 votes
Answer accepted
Ste Wright
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 15, 2020

Hi @Krzysztof Kiser 

I can see what you mean.

I tried to use a second Branch based on most recently created / all created issues from within the rule - which provides the error that no issues have been created.

I assume this is because the first branch moves to a related issue - rather than actioning against the trigger itself.

-----------------

I did find a workaround though using JQL.

Below your original rule, add as a component...

  • Branch: JQL (type of related issue) - JQL: issuetype = Sub-task and parent = HOME-1 and createdDate >= -1m and createdDate < 0m
  • Action: Comment On Issue - <<Comment Text>>

^ As long as no other sub-task is created for HOME-1 in the same minute, it should function as expected!

-----------------

Let us know if this works for you :)

Ste

Krzysztof Kiser
Contributor
August 15, 2020

@Ste Wright thank you very much for this. It will work very well for me. 

One more questions, perhaps you'd know. 

When setting up the comment action inside Jira Automation, there is an option to uncheck if I don't want to send a notification for this comment. 
It says you can only do this for public comments, but my comment visibility is set to pubic and the check box is inactive for me. 

Screen Shot 2020-08-15 at 11.37.06 AM.pngAny idea on how to fix this? 
I've already red the Jira issue they refer to, but it doesn't seem to answer my question. 

Ste Wright
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 15, 2020

Hi @Krzysztof Kiser 

I don't see this option - although I'm using Jira Cloud.

It might be that this a Service Desk option, as JSDSERVER-5599 appears to relate to an issue between internal and customer-facing comments (which might be what public refers to), as opposed to comment security within Jira issues.

Ste

Krzysztof Kiser
Contributor
August 15, 2020

@Ste Wrightyou're probably right that this option is only for Service Desk. That's a shame though, I think it would be very useful for non service desk users as well.

Anyway, thank for the help.

Like Ste Wright likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events