Skip to content
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

Support case-insensitive search for all views #161

Draft
wants to merge 6 commits into
base: dev-ignore-case-searching
Choose a base branch
from

Conversation

qu8n
Copy link
Collaborator

@qu8n qu8n commented Sep 18, 2024

Changes:

  1. Moved typeNames and queryTerms outside of the function so that they're only initialized once
  2. Simplified the code so that we don't have to handle single-value search and bulk search separately
  3. Updated the regex by adding ".*" in front of the search value so that the it can be matched anywhere inside the string. This removes the need for _CONTAINS

Note that the changes in yarn.lock were from the removal of the @neo4j/graphql-ogm package at the root level.

@qu8n qu8n force-pushed the requests-case-insensitive-search branch from 8ef9ac3 to fcefb0d Compare September 18, 2024 20:57
@qu8n qu8n changed the title Support case-insensitive and partial search for Patients page Support case-insensitive and partial search for Requests page Sep 18, 2024
@qu8n qu8n requested a review from ao508 September 18, 2024 21:01
@qu8n qu8n closed this Sep 19, 2024
@qu8n qu8n deleted the requests-case-insensitive-search branch September 19, 2024 14:07
@qu8n qu8n restored the requests-case-insensitive-search branch September 19, 2024 14:08
@qu8n qu8n reopened this Sep 19, 2024
ao508
ao508 previously requested changes Sep 19, 2024
Copy link
Collaborator

@ao508 ao508 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good so far! Just aded a reminder that we still want to support the _CONTAINS searching

frontend/src/pages/requests/RequestsPage.tsx Outdated Show resolved Hide resolved
@qu8n qu8n changed the title Support case-insensitive and partial search for Requests page Support case-insensitive and partial search Sep 19, 2024
@qu8n qu8n dismissed ao508’s stale review September 19, 2024 16:53

Removing this change request as we have discussed over Zoom. The new regex handles partial string matching and eliminates our need for _CONTAINS.

@qu8n qu8n force-pushed the requests-case-insensitive-search branch from fcefb0d to 3847c4c Compare September 19, 2024 20:40
@qu8n qu8n changed the title Support case-insensitive and partial search Support case-insensitive search for all views Sep 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants