Skip to content

Allow filtering of issues by milestone title wildcards in GraphQL

What does this MR do?

Resolves #328605 (closed) by adding the ability to filter issues by milestone wildcard values None, Any, Upcoming (incl. negated), and Started (incl. negated) through the GraphQL API.

issues/merge requests REST API endpoint needs to be updated to match the GraphQL API and this is tracked in a separate issue. #335939 (closed)

Sample Queries

Sample query 1:

{
  group(fullPath: "gitlab-org") {
    issues(milestoneWildcardId: ANY) {
      nodes {
        id
        title
        milestone {
          title
          startDate
          dueDate
	}
      }
    }
  }
}

Sample query 1 response:

{
  "data": {
    "group": {
      "issues": {
        "nodes": [
          {
            "id": "gid://gitlab/Issue/485",
            "title": "issue from public project 3",
            "milestone": {
              "title": "group milestone 1",
              "startDate": "2021-07-01",
              "dueDate": "2021-10-31"
            }
          },
          {
            "id": "gid://gitlab/Issue/484",
            "title": "issue from public project 2",
            "milestone": {
              "title": "public project milestone",
              "startDate": "2021-10-01",
              "dueDate": "2021-10-31"
            }
          }
        ]
      }
    }
  }
}

Sample query 2:

{
  group(fullPath: "gitlab-org") {
    issues(not: { milestoneWildcardId: UPCOMING }) {
      nodes {
        id
        title
        milestone {
          title
          startDate
          dueDate
	}
      }
    }
  }
}

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

Does this MR contain changes to processing or storing of credentials or tokens, authorization and authentication methods or other items described in the security review guidelines? If not, then delete this Security section.

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team
Edited by euko

Merge request reports