There is one request from the customer that when we select option from one of the cascading field the values in another single select field should change. I tried with following script but it is not working and showing only external service to all the option can some one help me on this. "211948", "211949" are the single field values.
211948 - External Service
211949 - Internal Service
def ProductLineComptField = getFieldById(getFieldChanged())
def cfield = getFieldByName("Request Type")
Map mapValue = ProductLineComptField.getValue() as Map
def cascadevalue = mapValue.get(0).toString()
if(cascadevalue.equals("Testing Services")){
cfield.setFormValue("211948");
} else {
cfield.setFormValue("211949");
}
switch (cascadevalue) {
case "Testing Services":
cfield.setFormValue("211948");
break
case "Local Consultancy Services":
cfield.setFormValue("211948");
break
case "Spatial Data Services":
cfield.setFormValue("211948");
break
case "RWT/ Quality Support":
cfield.setFormValue("211949");
break
case "Customer Escalation Support":
cfield.setFormValue("211949");
break
case "Support Data Normalization":
cfield.setFormValue("211949");
break
case "Data Analytics":
cfield.setFormValue("211949");
break
case "Support Data (Pre-) Processing and Ingestion":
cfield.setFormValue("211949");
break
case "Source Evaluation Support":
cfield.setFormValue("211949");
break
case "Release Support/TNM Support":
cfield.setFormValue("211949");
break
case "Media Observation Service":
cfield.setFormValue("211949");
break
case "Benchmarking":
cfield.setFormValue("211949");
break
default:
cfield.setFormValue("");
break
}