-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add way to filter programs
endpoints by majorid
and id
#97
Conversation
/v2/rest/programs/specializations
should have some way to filter by major idprograms
endpoints by major id
programs
endpoints by major idprograms
endpoints by majorid
and id
This is probably a feature update, not a bugfix, and is missing GraphQL. Until then it should probably be marked as a draft. |
programs
endpoints by majorid
and id
programs
endpoints by majorid
and id
I apologize for the dirty code. Thank you for all the reviews. |
You're good, first time for everything. Thanks for getting on it so fast. |
Good use of SQL literals, by the way. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One little thing, in the meantime I'll pull down for manual testing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This worked locally before your latest change. Appreciate the speed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@waterkimchi Great work on this 🙌, just a small semantic fix on the sql queries
@laggycomputer it looks like the majors list route is only returning majors with specializations from the |
Sounds right and also sounds really silly on my part. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔥
Description
Previously, the endpoints for programs returned a comprehensive list of all
majors
,minors
, andspecializations
without any filtering options. With this update, we have added the ability to query specific data by including optional parameters likemajorId
orminorId
. This enhancement allows users to request only the relevantspecializations
associated with a particularmajor
orminor
, streamlining the data retrieval process and improving the overall user experience.Related Issue
/v2/rest/programs/specializations
should have some way to filter by major id - #96Motivation and Context
Currently, the endpoint returns a list of all available specializations, which can be overwhelming and inefficient, especially for users seeking information about a specific
major
. By implementing this fix, users will be able to first retrieve themajor ID
through/programs/majors
, and then query/programs/specializations?majorID=BS-201
to get only the relevant specializations for a particular major, such asComputer Science
.How Has This Been Tested?
Tested using local environment.
Screenshots (if appropriate):
REST:
Majors:
Minors:
Specializations:
GraphQL:
Majors:
Minors:
Specializations:
Types of changes
Checklist: