Forums

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

How to blank or erase a field in the pop up screen.

J March 1, 2019

When the user tries to re-open a ticket, a pop up with a deadline (date field) is still with values.  This field is required. How do I blank this out on the pop up so the user can enter the appropriate date/deadline on Re-Open transition? 

 

1 answer

0 votes
Krishnanand Nayak
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.
May 15, 2019

You can use the Scriptrunner Behaviours to implement this request. Setup a project specific behaviour so that if the screen is shared with another project this behaviour will not load.

 

Here is the code snippet that you need to add on the Behaviour Intialiser

 

def screen = "Screen with Deadline Field" // the name of the screen
def deadLineField = getFieldByName("Deadline") // the name of the field you're validating

if (getFieldScreen().name == screen) {
deadLineField.setFormValue("")
}

Suggest an answer

Log in or Sign up to answer