In Behaviour on Jira cloud, I'd like to hide a specific field based on a value selected on other multi-select field.
For example - if one of the selected values (in the multi-select field) is "XYZ" then hide the relevant field.
What is the method to access and check the selected values?
This is my code which I know that works when it is using a single select field:
const myTeamsField = getFieldById("customfield_10022")
const severityField = getFieldById("customfield_10069")
// Check if it's the create view
if (isCreateView()) {
const myTeamsValue = myTeamsField.getValue()
if (myTeamsValue?.value == "Backend") {
severityField.setVisible(true)
} else if (myTeamsValue?.value == "backend") {
severityField.setVisible(false)
}
}
What should be changed? How?
TNX.