Skip to end of banner
Go to start of banner

Forbidding specific priorities for certain projects

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 13 Next »

 

Required apps

Power Scripts for Jira 2.5.2+ (server)

Level: BASIC

Problem

We want to forbid some issue priorities for certain projects during the issues creation, edit or project workflows transitions screens.

For example, we want to remove issue priorities `Blocker` and `Trivial` from the list of the available  options in the currently configured project.

Solution

By using lfRestrictSelectOptions SIL routine we'll easily manage to hide some issue priorities for certain projects. All you have to do is to create the following script and associate it with the main Live Fields configuration on your project, as described here. This way, the issue priorities will be hidden in create/edit/workflow transitions screens.

restrict_priorities.sil
string[] forbiddenPriorities = {"Blocker", "Trivial"}; //the array of the priorities to restrict
lfRestrictSelectOptions("priority", forbiddenPriorities);

Pay attention to the parameters passed in lfRestrictSelectOptions routine. You have to use quotes ("priority"), in order to pass in the actual field label name for the current screen.

Otherwise, SIL Interpreter will actually get the priority from the current issue.


See also

 

The above SIL script makes use of the lfRestrictSelectOptions routine offered by Power Scripts for Jira's Live Fields feature.

  • No labels