Confluence has been updated to version 6.15.9

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Status
subtletrue
colourGreen
titleJira serveron-premise

Introduction

Imagine you have two instances SD and DEV and you need to synchronize issues from SD to DEV.

...

The scripts below help to map the parent value from the cascading select list to the projects.

Sending side

Data FilterOutgoing sync

Snippet
replica.customFields."Product & Version" = issue.customFields."Product & Version"

...

Receiving side

 Map the parent value from the cascading select to the projects and if a mapping for the option is not found or the option is not selected, use PRODX as a default.

Create ProcessorIncoming sync

Snippet
def projectMapping = [
	"product_X": "PRODX"
	"product_Y": "PRODY"
	"product_Z": "PRODZ"
]

issue.projectKey = projectMapping[replica.customFields."Product & Version"?.value?.parent?.value] ?: "PRODX"



 Drop the synchronization (indicate that you don't want to create an issue on your side) if you don't find a mapping.

Create processorIncoming sync

Snippet
def projectMapping = [
	"product_X": "PRODX"
	"product_Y": "PRODY"
	"product_Z": "PRODZ"
]

def projectKey = projectMapping[replica.customFields."Product & Version"?.value?.parent?.value]

if (projectKey != null) {
  issue.projectKey = projectKey
  // your entire create processor goes here
  // ...
}

...



See Also

 

Content by Label
showLabelsfalse
showSpacefalse
cqllabel = "customfieldhandling"