-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
feat(server): add album filter to search tab #16979
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
Conversation
bo0tzz
left a comment
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.
Thanks!
Your description mentions tests but I don't see those in the diff, did you forget to push them?
.gitignore
Outdated
| mobile/ios/fastlane/report.xml | ||
|
|
||
| vite.config.js.timestamp-* | ||
| requests.http |
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.
Patterns which are specific to a particular repository but which do not need to be shared with other related repositories (e.g., auxiliary files that live inside the repository but are specific to one user’s workflow) should go into the $GIT_DIR/info/exclude file.
Hi bo0tzz. Fixed the .gitignore. The functional tests with the actual images I did locally on my machine. The unittests that I modified are here: main...DarrenMa:immich:feature/12258#diff-cb7433da384004a1abf31a700895fcfe157a0b98bfb09a67704e1d3cde417163 I'm at your disposal for any updates that you require. |
mertalev
left a comment
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.
Thanks for the PR!
You added e2e tests for when albumIds is null or empty, but it doesn't test that it filters by album when it's non-empty.
|
I added an e2e for a valued albumIds param and a bad check for an invalid format albumsIds param. |
|
@DarrenMa so you've added the following:
It would be great to expand this to allow the also these searches:
|
This is far beyond the scope of this PR and also requires some brain cells to come up with a solution that still performs well (negatively lookups generally are slow). Also, this is something that's not limited to album names but pretty much every search filter. So please don't post in some unrelated PR. There are already feature requests for all of this. |
feat(server): Add Album Filter to Search Tab #12258
Description
Implements the server API part of allowing for search of assets within albums.
Fixes #12258
How Has This Been Tested?
Test Setup
Total of 6 images:
Mario Album
20160331195151!SMB_Small_Mario_Jumping_Sprite.png287px-Mario_art15.png537px-Brosscared.pngLuigi Album
537px-Brosscared.png(also in Mario Album)553px-NSLU_Luigi_and_Yoshi_Artwork.pngNo Album
588px-Peach_&_Bowser.png600px-Bowser_SMB3_artwork.jpgNote:
537px-Brosscared.pngappears in both the Mario and Luigi albums.Test Cases
Unittests
'POST /search/metadata'.albumIdsis empty.API Changes
The
/api/search/smartendpoint accepts new optional param"albumIds":[]The
/api/search/metadataendpoint accepts new optional param"albumIds":[]The
/api/search/randomendpoint accepts new optional param"albumIds":[]Checklist:
make open-apisrc/services/uses repositories implementations for database calls, filesystem operations, etc.src/repositories/is pretty basic/simple and does not have any immich specific logic (that belongs insrc/services/)