Change comment visibility via email
I am trying to create a workflow that will create a comment only visible to a specific group. For some reason it turns the whole issue to be only visible to the reporter and the group. I would like it to only apply to the comment only and not the entire issue.
rule Change comment visible to
when issue.comments.isNotEmpty && comments.last.author.isInGroup("Dev"){
if(comments.added.first.text.contains("@Dev",ignoreCase)){
applyCommand("visible to Dev");
}
}
Please sign in to leave a comment.
the methos applyCommand() is always applied to a target issue, in your example to a current issue.
To set up visibility group to a comment please use the 'permittedGroup' field: comments.added.first.permittedGroup = {group: New Users};
Issue reporter always has access to own issue and get notifications using standard subscription on the saved search 'Reported by me'.
when issue.comments.added.isNotEmpty && comments.last.author.isInGroup("Dev") { if (comments.added.first.text.contains("@dev", ignoreCase)) { comments.added.first.permittedGroup = {Dev}; } }So there is no way the issue report will not see the developers note?