JMWE DC: Cannot read child values from cascading fields
Problem
Reading a child value from a cascading field in JMWE for Jira Data Center always returns a null value, even when the value is set:
For example, the script below is not correct:
issue.get("customfield_12213")?.get(1)Solution
The error is caused by the get() method used to retrieve the child value, which requires a String parameter "1" instead of an integer value of 1. Replacing the code with a String will resolve the problem. The script below correctly returns a child value of the cascading field.
issue.get("customfield_12213")?.get("1")Replace 12213 with the ID of the cascading custom field.