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

Accept Special Character Input For Patient Name in the Patient registration form #9217

Open
2 tasks
nihal467 opened this issue Nov 26, 2024 · 3 comments · May be fixed by #9116
Open
2 tasks

Accept Special Character Input For Patient Name in the Patient registration form #9217

nihal467 opened this issue Nov 26, 2024 · 3 comments · May be fixed by #9116
Labels
P1 breaking issue or vital feature work-in-progress

Comments

@nihal467
Copy link
Member

nihal467 commented Nov 26, 2024

Describe the bug

When creating a patient with a name containing special characters like an apostrophe ('), such as " Sam O'Brian ", the name is saved as " Sam Obrain ". The issue arises because the startCase and toLower provided by lodash package implemented in the frontend removes special characters during formatting.

Context: The auto-capitalization package was introduced after feedback from users who often entered names with inconsistent capitalization.

To Reproduce
Steps to reproduce the behavior:

  1. Go to patient tab
  2. Click on add patient details button
  3. Create a patient with the name " Sam O'Brian "
  4. See error in the patient details page

Expected behavior

  • The auto-formatting logic should only trigger after detecting a space and should capitalize the next letter in the patient registration form
  • Special characters, such as apostrophes ('), should be preserved as they are an integral part of many names.

Screenshots

Image
Image

@nihal467 nihal467 changed the title Disable Auto-Capitilasation Package in the patient registration form from removing special character Accept Special Character Input For Patient Name in the Patient registration form Nov 26, 2024
@nihal467 nihal467 added the P1 breaking issue or vital feature label Nov 26, 2024
Copy link

⚠️ Refrain from assigning this issue to yourself if you have another P1 issue assigned that is not yet closed.

@rithviknishad
Copy link
Member

Possibly would be fixed along with #9116

@Jacobjeevan
Copy link
Contributor

Possibly would be fixed along with #9116

It will 👍

.split(/[\s.'-]+/)
will split by hypens, apostrophe and periods, will capitalize accordingly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P1 breaking issue or vital feature work-in-progress
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants