Skip to content

Adding 'IssueFinder' for 'projects' API endpoint

What does this MR do?

Fixes the incoherent filtering by milestone in /projects/:id/issues and /groups/:id/issues endpoints, probably additional filtering issues.

Are there points in the code the reviewer needs to double check?

I think not. There are no tests for these api endpoints AFAIK and I'm not familiar with the codebase.

Why was this MR needed?

see above

Screenshots (if relevant)

A properly working API call:

$ curl -s -H "PRIVATE-TOKEN: $GITLAB_DEV_TOKEN" "http://localhost:3000/api/v3/projects/9/issues?milestone=No%20Milestone" | jq .
[
  {
    "id": 85,
    "iid": 3,
    "project_id": 9,
    "title": "No milestone issue",
    "description": "This issue will not have a milestone",
    "state": "opened",
    "created_at": "2016-10-12T10:55:20.070Z",
    "updated_at": "2016-10-12T10:55:26.608Z",
    "labels": [
      "label1"
    ],
    "milestone": null,
    "assignee": {
      "name": "Panagiotis",
      "username": "atma",
      "id": 27,
      "state": "active",
      "avatar_url": "http://localhost:3000/uploads/user/avatar/27/avatar.png",
      "web_url": "http://localhost:3000/u/atma"
    },
    "author": {
      "name": "Panagiotis",
      "username": "atma",
      "id": 27,
      "state": "active",
      "avatar_url": "http://localhost:3000/uploads/user/avatar/27/avatar.png",
      "web_url": "http://localhost:3000/u/atma"
    },
    "subscribed": true,
    "user_notes_count": 1,
    "upvotes": 0,
    "downvotes": 0,
    "due_date": null,
    "confidential": false,
    "web_url": "http://localhost:3000/atma/test-projeect/issues/3"
  }
]

Does this MR meet the acceptance criteria?

What are the relevant issue numbers?

23244

Merge request reports