-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
## Summary Fixes #1455 ### Time to review: __10 mins__ ## Changes proposed Implements logic for the query field in the search API Updated the seed script to allow you to generate more opportunities locally ## Context for reviewers This logic is deliberately very, very simple at the moment. It basically just does a text contains check across several columns. This is the most naive approach, and it is expected that if you tried to search two separate words at the same time, you probably won't get any results. A few options we may consider later (depending on the level of effort we want to put into a non-search-index approach): - Postgres text search / tsvectors: https://www.postgresql.org/docs/current/textsearch.html - Postgres text similarity: https://www.postgresql.org/docs/current/pgtrgm.html ## Additional information The `ids` function I added for the tests was because there are a lot of tests and when test `16` fails, its really hard to figure out which one that is. Now it outputs the request+expected results: ![Screenshot 2024-03-21 at 10 47 34 AM](https://github.com/HHS/simpler-grants-gov/assets/46358556/a7732375-00a8-4e4f-8e16-c00114a80342) --------- Co-authored-by: nava-platform-bot <platform-admins@navapbc.com>
- Loading branch information
1 parent
7f050b7
commit 2b205af
Showing
7 changed files
with
392 additions
and
27 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.