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

Fixing sync issue of phone number #25

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

kushboojain-iplit
Copy link

Avni contract has changed for phone number, it returns a Map instead of string

@@ -119,7 +120,8 @@ private OpenMRSPatient createPatient(Subject subject, SubjectToPatientMetaData m
String phoneNumberUuid = metaData.getPersonAttributesMappingList().getBahmniValueForAvniValue("Phone Number");
if (subject.getObservation("Phone Number") != null && phoneNumberUuid != null){
OpenMRSSavePersonAttributeType phoneNumberAttributeType = new OpenMRSSavePersonAttributeType(phoneNumberUuid, "phoneNumber");
OpenMRSSavePersonAttribute phoneNumberAttribute = new OpenMRSSavePersonAttribute(phoneNumberAttributeType, (String) subject.getObservation("Phone Number"));
Map<String, Object> phoneNumberObs = (Map<String, Object>) subject.getObservation("Phone Number");

Choose a reason for hiding this comment

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

@kushboojain-iplit Can you make this backward-compatible ? This will break for implementations running with older version of avni-serer

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