Skip to content

Allow passing arrays of labels in Epic GraphQL mutations

What does this MR do and why?

Allows API users to add/remove labels from Epics via GraphQL using the labels title, rather than just via the labels IDs

Screenshots or screen recordings

N/A

How to set up and validate locally

Use the following GraphQL examples in http://gdk.test:3000/-/graphql-explorer

mutation {
  createEpic(input: {groupPath: "flightjs", title: "test", addLabels: ["Brone"]} ) {
    epic {
      iid
      title
      labels {
        edges {
          node {
            title
          }
        }
      }
    }
  }
}
mutation {
  updateEpic(input: {groupPath: "flightjs", iid: "47", title: "test 1", removeLabels: ["Brone"], addLabels: ["Lusche", "Phickfunc"]} ) {
    epic {
      iid
      title
      labels {
        edges {
          node {
            title
          }
        }
      }
    }
  }
}

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #367082 (closed)

Edited by Andrew Smith

Merge request reports