Forums

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

Jira Cloud - mixed levels for users premium/standard

Emilia KASPRZYK
Contributor
November 25, 2020

Hi

I would like to ask is there any possibility to mix access levels to Cloud Jira Software.

I need to mix users between standard and premium level. Some ppl from my team need advanced roadmaps (available for premium) and some of them don't need it.

I have over 100 users and only 10% need premium level for more advanced functionalities. How to resolve this problem?

Greetings, Emilia

2 answers

1 accepted

1 vote
Answer accepted
Louisa Pabst
July 26, 2015

 So with the following code it works:

def numberselected = issue.getCustomFieldValue(ComponentManager.getInstance().getCustomFieldManager().getCustomFieldObjectByName("Checkbox Customfield")).size();

 Thanks Nic for your help smile

 

Best regards,

Louisa

1 vote
Nic Brough -Adaptavist-
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 Champions.
July 23, 2015

I'd go with

def numberselected = cfValues['Checkbox Customfield']?.getValue().size()

The getValue should be returning an array of all the currently selected options, so all you should need to do is count them, and you can do that with the size function.

Louisa Pabst
July 23, 2015

Thank you for fast response! Unfortunately, it still does not work. Do I have to define cfValues? Or do I have to import anything to be able to use cfValues?

Nic Brough -Adaptavist-
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 Champions.
July 23, 2015

Ah, I was assuming you'd only given a snippet of script and had already dealt with fetching cfValues in a bit you hadn't posted. From scratch, you should be able to use this in a scripted field: def numberselected = getCustomFieldValue("Checkbox Customfield")?.getValue().size() If you're running this somewhere else, it may need to change.

Louisa Pabst
July 23, 2015

I'll use it in a scripted postfunction! I tried: def numberselected = issue.getCustomFieldValue(ComponentAccessor.getCustomFieldManager().getCustomFieldObjectByName("Checkbox Customfield"))?.getValue().size(); But it still does not work!

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events