-
-
Notifications
You must be signed in to change notification settings - Fork 0
Description
Branch Name
feature/64-filter-projects-status-length
Task
The goal is to edit the GraphQL endpoint for projects to allow filtering. We will filter projects by project length and project status.
Why GraphQL and not REST? REST is awesome for simple querying commands while GraphQL is a lot more flexible. In fact, it is recommended and better practice to use GraphQL when it comes to filtering, sorting, and pagination, etc. Remember that using GraphQL means we can also control exactly what information we want to be returned to us, which is convenient. And this is all using just one endpoint too 💃
Inputs: (note they are all optional! and users can input one or more options! check Figma link I sent in the Slack for the visual idea of what this functionality is gonna do)
Project Length - look at nonprofit_chapter_projects for end_date and start_date
Project Status - look at nonprofit_chapter_projects for project_status
The plan is that in the frontend, the user will pick 1+ types of project_status and they will be all string inputs in our GraphQL. And then within our resolvers, we will convert the strings into IDs and do whatever JOIN commands necessary. Refer to https://docs.google.com/document/d/1tE_8BkrLbqR_SMnS2NA_ro1-d_y7V1rx-6VexejoN38/edit?tab=t.0 highlighted in green to get an idea of how you can get the proper data we need!
Test using Postman, and make sure to screenshot your results when you make your PR!
Image from Figma for this:
Acceptance Criteria
- Correct project length filtering (longest to shortest and vice versa)
- Correct project status filtering (can apply more than one status)
Checklist
- I have checked for duplicate issues.
- I have assigned the issue to the correct project board.
- I have tagged the issue properly.
Code of Conduct
- I agree to follow this project's Code of Conduct
Metadata
Metadata
Assignees
Labels
Type
Projects
Status