In this example, issue links between issues with the same custom field value should be added avoiding duplicate links, e.g.
Given three issues with the same value for the custom field "Custom-ID", Ticket A, Ticket B and Ticket C. When executing the transition on Ticket A, Ticket B and C should be linked to Ticket A. When now executing the transition on Ticket B, only Ticket C should be linked to Ticket B since Ticket A was already linked in the previous transition execution. In order to add issue links on a transition, the Create issue link post function is used.
The configuration will look like this:
Issues returned by JQL expression is: key != %{00015} and Custom-ID ~ %{12200} and key not in linkedIssues(%{00015})
Note that:
Once configured, the transition will look like this:
See Result screenshots "Create issue links based on a custom field value avoiding duplicates"