stable

Clone or download

Read-only

feat: Filter on labels in REST route

part of story #35825 Pull request new home page - Filter on labels How to test: - Add a label "emergency" and "easy fix" on one pull-request - Add a label "easy fix" on a second one - Query `GET /git/:id/pull_requests` with `query={"labels": [{"id": emergency_id}, {"id": easyfix_id }]}` --> Only the first pull-request is returned Change-Id: I1f7b68b6a7a9d08500709dccd24a5217815f6663

Modified Files

Name
M plugins/pullrequest/db/install.sql +2 −1 Go to diff View file
A plugins/pullrequest/db/mysql/updates/2024/202402061536_add_index_pull_request_label.php +39 −0 Go to diff View file
A plugins/pullrequest/include/PullRequest/Criterion/LabelCriterion.php +30 −0 Go to diff View file
M plugins/pullrequest/include/PullRequest/Criterion/SearchCriteria.php +2 −0 Go to diff View file
M plugins/pullrequest/include/PullRequest/Dao.php +32 −12 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/RepositoryResource.php +4 −0 Go to diff View file
M plugins/pullrequest/tests/integration/DaoTest.php +38 −2 Go to diff View file
M plugins/pullrequest/tests/unit/REST/v1/RepositoryPullRequests/QueryToSearchCriteriaConverterTest.php +24 −0 Go to diff View file