Hi there - I have a custom field that was created through the advanced settings where I create a dimension called “team” and assign a name to each of my projects. My issue is that when I update the code to add an additional board I don’t see the changes reflected in my dashboards (eg. the team that I added does not exist there). See below: I have changed the names of the boards to reflect what I am trying to do. The bolded text is what I am trying to add.
creates team as dimension (filter by team)
[jira.customfield_teamname]
name = “Team”
data_type = “string”
dimension = true
json_fields = [“Project”, “customfield_10029”]
javascript_code = ‘’’
if (issue.fields.project.name == “P”) {
issue.fields.customfield_teamname = “S”;
} else if (issue.fields.project.name == “D”) {
issue.fields.customfield_teamname = “P”;
} else if (issue.fields.project.name == “DR”) {
issue.fields.customfield_teamname = “C”;
} else if (issue.fields.project.name == “W” && (issue.fields.customfield_10029 && issue.fields.customfield_10029.value == “E”)) {
issue.fields.customfield_teamname = “E”;
} else if (issue.fields.project.name == “W” && (issue.fields.customfield_10029 && issue.fields.customfield_10029.value == “G”)) {
issue.fields.customfield_teamname = “G”;
} else if (issue.fields.project.name == “W” && (issue.fields.customfield_10029 && issue.fields.customfield_10029.value == “O”)) {
issue.fields.customfield_teamname = “O”;
} else if (issue.fields.project.name == “M” || (issue.fields.project.name == “W” && (issue.fields.customfield_10029 && issue.fields.customfield_10029.value == “K”))) {
issue.fields.customfield_teamname = “K”;
} else if (issue.fields.project.name == “TEST BOARD”) {
issue.fields.customfield_teamname = “TEST”;
} else {
issue.fields.customfield_teamname = “(none)”;
}
return issue.fields.customfield_teamname;
‘’’