Hi
Could you please help me to keep a field available with other field's value?
Only when user set the Automation Status as Automated, Test Cases Reference will be shown below the Automation Status.
Thanks,Anusha
I tried below script but nothing worked
def automationStatusField = getFieldById(getFieldChanged())def testCaseReferenceField = getFieldById("customFieldId=14781")
String automationStatusVal = automationStatusField.getFormValue();
if(automationStatusVal.equals("Automated")){testCaseReferenceField.setReadOnly(true);} else {testCaseReferenceField.setReadOnly(false);}
Hi @Anusha Iyer
I guess you're using wrong syntax for custom field ID, it should be customfield_14781
def automationStatusField = getFieldById("customfield_XXXXX") //Automation Status fielddef automationStatusFieldType = automationStatusField.getValue()def testCaseReferenceField = getFieldById("customfield_14781") // TestCase Reference fieldif(automationStatusFieldType == "Automated"){testCaseReferenceField.setReadOnly(true);} else{testCaseReferenceField.setReadOnly(false);}
Please change customfield_XXXX to your Automaton Status cf ID.
Please try this code adding in behavior script and under Automation Status field.
RegardsTej
It looks like you're new here. Sign in or register to get started.