how can I do this via script runner? Jira server v8.5.0
Hi @Helen Ahlberg you need to use postfunction. Snippet with the example code is here: https://library.adaptavist.com/entity/add-comment-to-an-issue-in-a-post-function
I want to have a pre-defined value comment on every transaction.
Not a comment after the action is done but during the transaction
ex
My issue is moved from A to B and when pressing go_to_B I want a predefined value shown
ex: Enter the check you have done:
so that users can enter a comment after, And I want all of this to end up under Comment (not a custom field)
Is this possible?
https://community.atlassian.com/t5/Jira-questions/Automatically-add-a-comment-to-jira-issue/qaq-p/454647
but how can I do this in Script Runner?
Hi @Helen Ahlberg are you familiar with Behaviours (https://scriptrunner.adaptavist.com/6.20.0/jira/behaviours-overview.html)?
You can use this code in Behaviours script
def predefinedComment = "some comment"getFieldById("comment").setFormValue(predefinedComment)
It looks like you're new here. Sign in or register to get started.