Forums

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

Behaviour script works in create screen but not in transition screen

Deleted user July 19, 2023

Hi Team,

Below is my requirement,

1. When i select a Checkbox custom field values as Yes, few field needs to be shown mandatory and few fields should be read-only

2. When uncheck the Custom field value, few fields should be mandatory and visible.

 

I tried with a script in Behaviour. But it is working in the create screen, but not in the transition screen.

Could you please help me here

 

Note: I have selected "On Load" and "On Change" checkboxes in Behaviour script runner.  I tried with multiple combinations by checking only one checkbox also. Still no luck

1 answer

0 votes
Kian Stack Mumo Systems
Community Champion
July 19, 2023

@[deleted], 

 

According to this post - https://docs.adaptavist.com/sr4jc/latest/features/behaviours#behaviours-supported-functions, ScriptRunner begaviors do not work on transition screens.

Deleted user July 19, 2023

Hi @Kian Stack Mumo Systems 

Is there any way we can achieve this requirement?

other than create screen, during edit or something like that?

Please help me with this Kian

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.
July 19, 2023

Yep, Atlassian doesn't yet support building Behaviours in screens other than "create"

Kian Stack Mumo Systems
Community Champion
July 19, 2023

You can make fields required depending on the options selected using a scriptrunner validator, but you cannot optionally hide/show them.

 

The solution would be to write a validator that fails if a certain value is chosen and the other fields are not filled out. 

Deleted user July 19, 2023

Yes understood Nic. But we have a tough requirement, when a field is selected, other fields should be mandatory.

please help me in understanding this - will it be achieved in any other way?

Deleted user July 19, 2023

hi @Kian Stack Mumo Systems 

Could you please provide me sample validator scripts for the one you mentioned above

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events