Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

how can I add links type as dependency

Yingyi November 23, 2023

I need to create new issue link types

like start to start, finish to start, so when I change a issue's time, its dependency changes automatically 

2 answers

0 votes
Kristian Walker _Adaptavist_
Community Champion
November 23, 2023

Hi Yingi,

I can confirm that if you use ScriptRunner for Jira Cloud then you can write a script to run as a script listener and automatically add or remove issue links when a script is updated or created using a Script Listener.

Your script would need to check if the value of your required field had changed using the issue changelog, and we have an example of checking the changelog in the example here that you can use as a guide.

If the correct field has changed, then you can add an issue link, and the example here shows how to create an issue link on line 51. 

Also, to delete a current issue link, you can call the Delete issue link API, passing in the ID for the issue link, which you can get from the issue object in the script listener.

You can use these examples to help create a script to solve your requirements.

I hope this information helps.

Regards,

Kristian

0 votes
Ste Wright
Community Champion
November 23, 2023

Hi @Yingyi 

You can create new link types as a Product Admin:

  • Go to Settings (cog icon in top-right) > Issues
  • Select Issue linking from the left hand menu
  • Use the fields near the bottom of the page to add new link types

See more information on this help page: Configure issue linking

If you then want to automate actions using linked issues, you can do this using Automation

Ste

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
TAGS
AUG Leaders

Atlassian Community Events