Include custom meals in Product/Food search results#304
Open
LarytheLord wants to merge 2 commits intosimonoppowa:developfrom
Open
Include custom meals in Product/Food search results#304LarytheLord wants to merge 2 commits intosimonoppowa:developfrom
LarytheLord wants to merge 2 commits intosimonoppowa:developfrom
Conversation
Author
|
Pushed a follow-up technical pass in commit 40c5232 to strengthen coverage for this search behavior:\n\n- added a test that verifies custom meals can match by brand (case-insensitive), not only by name\n- added a test that verifies deduplication still works when custom meals have no code (fallback name-based key path)\n\nThis should make the custom-meal prepend logic safer against edge cases in real intake history. |
40c5232 to
c5fdae3
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Custom meals were only discoverable in the Recently added tab, because Product/Food search paths queried remote OFF/FDC sources only. This made reusing manually created meals hard, as reported in #267.
This PR includes matching custom meals from recent intake at the top of both Product and Food search results.
Changes
SearchProductsUseCaseto read recent intake viaGetIntakeUsecase.MealSourceEntity.customsource + code/namelocator.dartfor the new use case dependency.search_products_usecase_test.dartcovering:Notes
I could not execute Flutter tests in this environment because
flutteris not installed (command not found).