Hi,
I am new to the Scriptrunner listener and look for example how to filter activationonly when two custom fields have been change.
So I choose Identify by issue updated and now I need to put the condition to trigget only when customField_AAA or customField_BBB have been change.
what is the sintex to write this condition?
Hi Jacob,
Thank you for your question.
I can confirm that when configuring a Script Listener with ScriptRunenr for Jira Cloud that you can configure conditions based on the Jira Expression Framework as described in the documentation page located here.
Also, I can confirm that when writing a listener you can see what properties are available in the context of the script by clicking the Show Me link next to the text which says There are parameters/variables that are automatically available for use within your script:.
I can confirm that when you configure your listener to fire on the Issue Updated event that one of the properties is the changelog map variable which contains details of all of the objects which have been updated on an issue.
This means that to achieve your requirement you should check to see if the custom fields you require were updated in the changelog and if they were then to run the code you require and if they were not then to do nothing.
If this response has answered your question can you please mark it as accepted so that other users can see it is correct when searching for similar answers.
Regards,
Kristian
But I didn't use Scriptrunner for cloud
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.