I have two JSM team managed (!) projects that I use as internal servicedesks in my organisation.
Sometimes one workflow triggers another workflow. I wish to automate ticket creation to streamline our business process.
I have created an automation in the source project that, when the issue reaches particular status, creates a new issue in the target project. I was also able to able to set the "summary" field in the target issue as a copy from the source issue.
Now I wish to
1. set the "reporter" field of the target issue based on a custom field from the source issue. I tried to set "additional fields" under "more options" as:
{
"fields": {
"reporter": {"id":"{{issue.customfield_10088.accountId}}"} ,
}
}
but it doesn't work. I guess I have to somehow explicitly state which is source and which is target issue?
2. take a form that was attached to the source issue and copy it over to the target issue. If that is impossible, I would be fine to attach a pdf snapshop of this form to the target issue.
Thanks very much in advance for any tips!
Hello @Lukasz
Please show us the complete rule that you have created. Often problems are based on the current context of a given step, and we can't determine the context without seeing the complete rule.
If you want to reference fields from the issue that triggered the rule, anywhere in the rule you can use the {{triggerIssue}} object (rather than the {{issue}} object). That might be all you need to solve your first question.
It seems like it might not be possible to copy a form from one issue to another within an Automation Rule, based on this, except by using the workaround which requires using the Send Web Request action to call the REST API:
If you want to reference fields from the issue that triggered the rule, anywhere in the rule you can use the {{triggerIssue}} object (rather than the {{issue}} object)
Thank you! This solved the first point.
I'll give API solution for point 2 a shot, it looks like what I need.
Thanks again!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Lukasz The below should work to copy the value of the user custom field from the source to the 'Reporter' on the target.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you for the response, @Gikku
My custom field unfortunately does not appear in the dropdown list, so this solution doesn't work.
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.