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

Script runner - Behavious - Field required

Hello,

I have setted up a behaviour to make a field required based on another field like this:

import com.onresolve.jira.groovy.user.FieldBehaviours
import groovy.transform.BaseScript

@BaseScript FieldBehaviours fieldBehaviours

def testableField = getFieldById(fieldChanged)
def testRemarksField = getFieldByName("test remarks")

testRemarksField.setRequired(testableField.getValue() == 'no')

If I edit a task with the testableField to no, I see that the field is required:

jira_tabs.png

And the field is also marked as required:

jira_field.png

But if I validate the form again, it won't ask again this field even if it's still empty. How is it possible?

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS

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