diff --git a/src/locales/en-US/translation.json b/src/locales/en-US/translation.json index 3302ef48e3..899af3db21 100644 --- a/src/locales/en-US/translation.json +++ b/src/locales/en-US/translation.json @@ -33,6 +33,9 @@ "types": { "charity": "Charity", "private": "Private" + }, + "errors": { + "patientNameRequired": "Patient Given Name is required." } }, "sex": { @@ -52,9 +55,6 @@ "states": { "success": "Success!" }, - "errors": { - "patientNameRequired": "No patient name entered!" - }, "scheduling": { "label": "Scheduling", "appointments": { diff --git a/src/patients/new/NewPatientForm.tsx b/src/patients/new/NewPatientForm.tsx index aa209f8cc0..9a9eb3950c 100644 --- a/src/patients/new/NewPatientForm.tsx +++ b/src/patients/new/NewPatientForm.tsx @@ -39,7 +39,7 @@ const NewPatientForm = (props: Props) => { const onSaveButtonClick = async () => { if (!patient.givenName) { - setErrorMessage(t('errors.patientNameRequired')) + setErrorMessage(t('patient.errors.patientNameRequired')) } else { const newPatient = { prefix: patient.prefix, @@ -98,7 +98,7 @@ const NewPatientForm = (props: Props) => {

{t('patient.basicInformation')}

- {errorMessage && } + {errorMessage && }