I have a process for problem tickets.
Problem stores the date of the oldest linked ticket created date in a field.
When you link a new incident, it checks the created date of that ticket, against the stored date. If the newly linked ticket is "older", then that stored date is replaced by the date in the newly linked ticket. I then have automations that do calculations after that.
What I am stuck on, is if you de-link a ticket, then check the linked tickets for the now "oldest" date and set that as the stored field in the Problem ticket.
Hello @Terry Dance
You can use the Lookup Issues action to execute a JQL to find the tickets linked to the target ticket. Set the JQL to order by Created ASC. That will put the oldest ticket first in the results set.
To access information in that first item use
{{lookupIssues.first.fieldName}}
In that manner you can get the created timestamp of the oldest linked ticket.
What value would I put in the for issue key? The smart value isnt working.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please provide a screen image showing your complete rule. I can't tell you why it isn't working without that information.
This is an example of such a rule.
HOWEVER links are considered directional. When you remove a link two issues are affected. This rule will not necessarily be triggered by the issue you are viewing when you remove the link. It will be triggered by the issue that is considered the "source" in the link relationship.
Link Types have an Inward and Outward Description. For example:
link type name | Inward Description | Outward Description |
Blocks | is blocked by | blocks |
If the link between two issues is:
ABC-1 blocks ABC-2
ABC-2 is blocked by ABC-1
...then ABC-1 is considered the "source". When viewing ABC-1 you would see "blocks" (the Outward Description) in the Issue Links section, describing its relationship to ABC-2.
So, if you were viewing ABC-2 and removed the link to ABC-1, the rule would actually be triggered for ABC-1.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Its all good I used the lookupissues action and ordered them to have the oldest ticket first. I then clear the field that was storing the date of the oldest linked ticket, then input the created date of whatever the now oldest ticket is. Which then kicks off my calculations. So it now works for linking and unlinking.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Terry Dance,
From your description, it seems as if you already have all in place to go through the issues, lookup the oldest date and update your issue. So I assume your biggest problem is finding the issue that is no longer linked?
There is an automation trigger issue link deleted that you can use to identify the issues on both ends of the removed link. The following smart values identify those issues:
{{issue.key}}
{{destinationIssue.key}}
If you have those, I would assume you could fill the gap in your logic to kick off the calculations you are already able to perform.
Hope this helps!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Im just using a Issue Linked trigger, and comparing its createddate to the stored date I have on the automation.
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.