Skip to content

Commit

Permalink
(fix) use socialHealthAuthorityIdentificationNumber (#45)
Browse files Browse the repository at this point in the history
  • Loading branch information
donaldkibet authored Aug 26, 2024
1 parent aeef67b commit 9fb8e3a
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,10 @@ class PatientMapper extends Mapper<HIEPatient, FormValues> {
): Record<string, PatientIdentifierValue> {
const updatedIdentifiers: Record<string, PatientIdentifierValue> = { ...currentFormValues.identifiers };

// Map healthId to hiePatient.id
updatedIdentifiers.healthId = {
...currentFormValues.identifiers['healthId'],
// Map Social Health Authority Unique Identification Number to HIE Patient ID
// See https://github.com/palladiumkenya/openmrs-module-kenyaemr/blob/1e1d281eaba8041c45318e60ca0730449b8e4197/api/src/main/distro/metadata/identifierTypes.xml#L33
updatedIdentifiers.socialHealthAuthorityIdentificationNumber = {
...currentFormValues.identifiers['socialHealthAuthorityIdentificationNumber'],
identifierValue: hiePatient.id,
};

Expand Down

0 comments on commit 9fb8e3a

Please sign in to comment.