Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save vikrantyadav11/000b42d1f49a656ba894c748892abf86 to your computer and use it in GitHub Desktop.
Save vikrantyadav11/000b42d1f49a656ba894c748892abf86 to your computer and use it in GitHub Desktop.
const uacField = getFieldById("customfield_10322");
uacField.setRequired(true);
const mobileField = getFieldById("customfield_10323");
mobileField.setVisible(false);
mobileField.setRequired(false);
const productareaField = getFieldById("customfield_10536");
productareaField.setVisible(false);
// Get UAC field value
const uacFieldValue = uacField.getValue()?.value;
if (uacFieldValue == "Yes") {
mobileField.setVisible(true);
mobileField.setRequired(true);
//show option No only in Mobile Field
mobileField.setOptionsVisibility(["10537"], true)
} else {
mobileField.setVisible(false);
mobileField.setRequired(false);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment