Hello!
I have requirement, if the field have specific value, I have to show or hide other fields on JSM portal. And it works perfectly with usual fields and easy behaviour:
def projectCategory = getFieldByName("Category")
def otherProjectCategory = getFieldByName("Category Name")
def selectedOption = projectCategory.getValue() as String
log.debug "Selected option: $selectedOption"
if (selectedOption == "Other" ) {
otherProjectCategory.setHidden(false)
otherProjectCategory.setRequired(true)
}
else {
otherProjectCategory.setHidden(true)
otherProjectCategory.setRequired(false)
}But now instead of usual custom field “Category” I need to use Asset field “Category”. But then script is not working.
Is there any way to do it?