Hey guys,
My team and I are looking for ways to develop automation using scriptruner for Jira Cloud to copy the value of a custom field in project A to the same field in the item linked to project B.
Has anyone seen something similar and could help me, please?
Thanks!
Hi Ana,
It will depend on what action you want to copy the field value.
If you wanted to do it when an issue is created then you could use Behaviours and I can confirm we have some examples of how to use Behaviours here.
If you wanted to do it on an event such as when an issue is updated then you could use a script listener.
If it is just a one time task then we have the copy custom field values built-in script that you can use.
Finally, we also have an example script on the Script Console page called Copy Custom Field and this can be used as a reference to see the logic you would need to use to write a script to copy custom field values.
Using the example you could update the JQL that searches for the issue to update the field values on to return the linked issue to update the field on.
I hope this information helps.
Regards,
Kristian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can achieve this using Jira's automation with the following components :
- trigger : whatever you want
- Branch -> for linked issue (choose the link you want or choose all)
--> If condition on smart value {{issue.project.key}} equals your destination project or skip this step if you only have linked issues in a single project
---> Edit issue : pick your field and chose Copy from trigger issue
A screenshot would be clearer so there you go :
For more info, check the following link : https://www.atlassian.com/software/jira/guides/automation/overview#what-is-automation
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @said kouzibry
I tried to follow the rule you mentioned but even with the item containing linked issues in the log it says that there are no links and the automation does not occur as expected.
Do you know how to solve it?
Thanks!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.