Support search field option for iterations REST API
What does this MR do and why?
Related to #350991 (closed)
Allow the user of the iterations REST API to specify the search fields to perform a search in.
Right now we can search for iterations whose titles match the search
parameter.
http://gdk.test/api/v4/groups/71/iterations?search=plan
By using the added in
field, we can search for iterations whose cadence titles match the parameter search
as well.
http://gdk.test/api/v4/groups/71/iterations?search=plan&in[]=cadence_title
How to set up and validate locally
- Create an iterations cadence.
- Visit a group (it must be a group, not a project)
- In the sidebar menu on the left, navigate to
Iterations
underPlan
- Click
New iteration cadence
. - Enter some title and uncheck
Enable automatic scheduling
. - Click
Create cadence
.
- Populate the cadence with some iterations
video instruction
Visit the updated REST API endpoint:
http://gdk.test/api/v4/groups/71/iterations?search=lol&in[]=cadence_title
http://gdk.test/api/v4/groups/71/iterations?search=lol&in[]=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.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by euko