It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Behaviour with RefinedTheme Template Edited

Hello,

i've got a problem. My Behaviour script dosn't work with refinedtheme for JSD, without the refinedtheme it works perfectly. Here is the script.

import com.onresolve.jira.groovy.user.FieldBehaviours
import groovy.transform.BaseScript
import com.atlassian.jira.component.ComponentAccessor

if(getFieldById(getFieldChanged()).getValue() == 'Festangestellt'){

def mainKpi = getFieldByName("Funktion")

def customFieldManager = ComponentAccessor.getCustomFieldManager()
def optionsManager = ComponentAccessor.getOptionsManager()

def customField = customFieldManager.getCustomFieldObject(mainKpi.getFieldId())
def config = customField.getRelevantConfig(getIssueContext())
def options = optionsManager.getOptions(config)

def optionsMap = options.findAll {
it.value in ["Abrechnung","Controlling"]
}.collectEntries {
[
(it.optionId.toString()) : it.value
]

}
mainKpi.setFieldOptions(optionsMap)}

 

Does anybody got the same Issue or did anyone got fix this, that behaviour works fine with refinedtheme?

0 comments

Comment

Log in or Sign up to comment
TAGS
Community showcase
Posted in Jira Service Desk

How has Jira Service Desk increased productivity in your org?

Hi Jira Service Desk community, Atlassian is on a mission to unleash the potential of all teams, and we know that tools are just one piece of that puzzle. With Jira Service Desk, we have productiv...

164 views 0 3
Join discussion

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you