Allocate Assignee based on linked Issue (using Single Issue Linker)

Hightower D November 24, 2021

I have a parent issue of type "Group", and a child issue of type "Issue" however, I have created a custom field called "Linked Group" which is a single issue linker type field ( that points to the list of "Group" issuetypes. 

When an "issue" is transitioned from "Open" to "Assigned" via the "Assign" Transition I wanted to apply the following logic... 

  • IF there is a linked Group ( via the issue linker field ( called "Linked Group" ) then. 
  • Find the Linked Group's  Assignee value. 
  • Then update the "issue" object to make the issue.assignee == the linked group's assignee. 

I have looked at everything ( and everywhere)  however I cannot get it right..  -- Some of my challenges are: 

  • I dont actually know what link type is used on the issueLinker type ( I heard its not a bi-directional link) 
  • I dont know what the best way to implement this is ( since i do have ScriptRunner)
  • essentially, i could move the "Group" issue to a "Linked Epic" or "Parent"  -- however the users did want to see the field name "Linked Group" from the screen -- so also looking for advice there, 

Much thanks! 

1 answer

0 votes
Leonard Chew
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 26, 2021

Hi Hightower

I strongly recommend you to use Epics for your use case.
Epics have built-in functionalities you can use.

Creating a big workaround, only because your users are not happy with the word "Epic" instead of "Group", will lead to loads of problems that can be avoided.


That said...

I don't know what you mean with "Issue Linker" Field. Do you mean the "Issue Picker" Script Field provided by Scriptrunner?

As for your question:

You can achieve your workaround-goal by using a scriptrunner postfunction on your transition open->assigned

That script would get the assignee of the "linked group issue" and set it on the current issue (which is being transitioned)

Suggest an answer

Log in or Sign up to answer