Hi all. I hope someone can help. Our Jira uses a custom “labels” field that syncs with our partner’s system “labels” field. We want our labels to be added to their labels field without removing any of their existing labels. It’s a one-way sync. Their labels do not sync back to ours.
Currently, we use this line of script:
replica.labels = issue.customFields.“Labels”?.value
However, as mentioned earlier, it overwrites the existing data in our partner’s labels field. How do we keep it from overwriting?
Note: our custom field is also called “labels” - unfortunately I inherited it this way.
We need to see the Incoming sync from your customer side.
What you are using is correct, for the outgoing, because you are assigning the value of your custom fields to the replica.labels
Most probably they are getting repleace cause Exalate is trying to match the labels on both systems and if they have a label that you dont on the custom field it will get removed.
You could try usign issue.labels += replica.labels by usign the += you will be adding new labels but Exalate wont be able to remove the labels, even if you have removed any labels from your end.