-
-
Notifications
You must be signed in to change notification settings - Fork 854
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: Filter Recipes By Household (and a ton of bug fixes) #4207
feat: Filter Recipes By Household (and a ton of bug fixes) #4207
Conversation
…recipes-by-household
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.
I think i managed to have my review match the randomness of the gif.
Frontend is all i manage today. Will try to finish the rest tomorrow.
Its all just little comments. No obvious bugs yet. But will do some real world testing as well and see what i find.
Co-authored-by: Kuchenpirat <24235032+Kuchenpirat@users.noreply.github.com>
Co-authored-by: Kuchenpirat <24235032+Kuchenpirat@users.noreply.github.com>
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.
took me a bit longer than a day but i have no blocking comments.
Will leave it up to you to merge 🚀
…cipes#4207) Co-authored-by: Kuchenpirat <24235032+Kuchenpirat@users.noreply.github.com>
…cipes#4207) Co-authored-by: Kuchenpirat <24235032+Kuchenpirat@users.noreply.github.com>
…cipes#4207) Co-authored-by: Kuchenpirat <24235032+Kuchenpirat@users.noreply.github.com>
What type of PR is this?
(REQUIRED)
What this PR does / why we need it:
(REQUIRED)
This PR adds a household filter to the recipe search. It's a radio select, so you can only select one household or no households. This lets users find recipes based on a specific household (e.g. show me only my household's recipes):

Note there's a new "Clear Selection" button there too. You can click on the radio button a second time to deselect it, but I thought an explicit clear button would be easier to understand. This households filter only appears if there's two or more households to choose from (otherwise the filter would be useless). As expected, on public instances, only non-private households are shown here.
You wouldn't think this would be a pain to implement... but boy howdy did I uncover so many layers of jank. In addition to implementing the filter on the recipes page, here are all the things I changed on the frontend:
And on the backend:
Which issue(s) this PR fixes:
(REQUIRED)
Partially implements #4081
Special notes for your reviewer:
(fill-in or delete this section)
I swear this PR wasn't supposed to be very big
Testing
(fill-in or delete this section)
Frontend manual testing; added a bunch to pytest