Forums

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

How can I make a field "required" only after a specific state is reached?

miller j
Contributor
November 28, 2017

We want to make the "Fix Version" field a required field, but only later in the workflow.

I know we can use validators to do that, but i don't want to use validators, since we have too many transitions.

Any links or pointers?

Thanks - John.

 

1 answer

0 votes
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 Leaders.
November 28, 2017

I'm afraid validators are the answer to this one. 

You could try injected javascript (don't), or behaviours, but they're both by-passable, only work in some places, and hence prone to failure.  Validators is the only way to do it.

miller j
Contributor
November 29, 2017

Hi Nic,

Thanks for the quick reply

How can I use behaviours to achieve this?
Can we specify states in behaviors?

I was thinking something like this should work, but I need the exact syntax to specify states.

FormField Version= getFieldByName("Fix Version")

if(State=="Done"||State=="Closed" ){
Version.setRequired(true)
}

Thanks.

Suggest an answer

Log in or Sign up to answer