Add the ability to sort iterations by due date DESC
What does this MR do and why?
- Adds the ability to sort iterations by cadence and due dates (DESC)
- Adds a new model scope
- Modifies the finder
- Adds a new GraphQL enum for iterations sort
- Refactors an existing scope !98952 (comment 1116918442)
How to set up and validate locally
For the added scope, a typical GraphQL query we might use is:
{
group(fullPath: "gitlab-org") {
iterations(
iterationCadenceIds: ["gid://gitlab/Iterations::Cadence/16671"]
state: closed
sort: CADENCE_AND_DUE_DATE_DESC
first: 20
) {
nodes {
id
dueDate
state
}
}
}
}
It's corresponding DB query and its plan are: https://console.postgres.ai/gitlab/gitlab-production-tunnel-pg12/sessions/12295/commands/43658
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #372767 (closed)
Edited by euko