Page History
...
Set an option value manually into the local custom field
Snippet issue.customFields."Multi Select Custom Field name".value = (issue.customFields."Multi Select Custom Field name".value ?: []) + nodeHelper.getOption(issue, "Multi Select Custom Field name", "MY STATIC OPTION")
add the value from the remote custom field Departments into the local custom field Sub-divisions
leave an empty field in case there's no option, received from the remote sideSnippet issue.customFields."Sub-divisions".value = replica.customFields."Departments"?.value
Set a default option in case there's no value received from the remote side
You need to ensure that the value is an array of options.
Snippet issue.customFields."Hobby".value = replica.customFields."Interest"?.value ?: ["Running"]
Map options in a select list
Snippet def hobbyMap = ["Football": "Sports", "Baseball": "Basketball"] def remoteHobbies = replica.customFields."Hobby"?.value?.value issue.customFields."Hobby".value = remoteHobb iesremoteHobbies.collect{hobbyMap[it] ?: it}
...