The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

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

Behaviours Screen Condition

Steven Mustari
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.
January 16, 2020

Is there a way to condition a behavior based on the screen ID? I would like to easily map and organize my behavior rules per screen.

Regards,
Steven

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

1 vote
Answer accepted
Leo
Community Champion
January 16, 2020

Hi @Steven Mustari,

Yes, you can make a condition based on screen name or id

//condition based on name

if(getFieldScreen().name == "Screen Name"){

  //code here

}

//condition based on id

if(getFieldScreen().id == 1234){

  //code here

}

 

BR,

Leo 

Steven Mustari
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.
January 16, 2020

Thanks Leo! Exactly what I needed!