Forums

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

Control scriptrunner behavior by some project property?

Chris Amos May 24, 2018

I have a number of projects that share schemes and workflows, however the projects are not quite equal, some have greater control requirements.

Right now I have a complicated boolean algorithm on transition conditions, every time I create a project of the restrictive kind I have to update this logic.

I wonder if there is a way to set and query some property of the database, I could use this to control the transition, and it will be simpler to set a flag on restrictive projects.

It does not have to be a scriptrunner solution, but I do have it available.

1 answer

1 accepted

1 vote
Answer accepted
Alexey Matveev
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.
May 24, 2018

Hello,

As far as I understand you want to "mark" projects with certain flags so, that you later can analyse the flag and perform required actions. If so, you can use project properties. You can get project properties with ProjectPropertiesManager

https://docs.atlassian.com/software/jira/docs/api/7.6.1/index.html?com/atlassian/jira/component/ComponentAccessor.html

Chris Amos May 26, 2018

Thanks, the clue I needed, there is an add in to get and set properties, even has an entry in the transition condition list.

Always prefer the low admin way.

Chris 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events