Skip to content

Commit

Permalink
LNK-1871: One more.
Browse files Browse the repository at this point in the history
  • Loading branch information
ajagann1 committed Mar 13, 2024
1 parent 5ac8f11 commit 71b5e67
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public FhirBundleProcessor(Bundle bundle) {
Bundle.BundleEntryComponent e = bundle.getEntry().get(index);
Resource resource = e.getResource();
ResourceType resourceType = resource.getResourceType();
String id = resource.getIdElement().getIdPart();
String resourceId = resource.getIdElement().getIdPart();
String patientReference = FhirHelper.getPatientReference(resource);
if(resourceType.equals(ResourceType.Organization) &&
resource.getMeta().hasProfile(Constants.SubmittingOrganizationProfile)){
Expand All @@ -69,7 +69,7 @@ else if(resourceType.equals(ResourceType.Library) && ((Library) resource).getTyp
.anyMatch(c -> c.getCode().equals(Constants.LibraryTypeModelDefinitionCode))){
if(linkQueryPlanLibrary == null){
linkQueryPlanLibrary = e;
bundleEntryIndexToFileMap.put(index, String.format("census-%s.json", id));
bundleEntryIndexToFileMap.put(index, String.format("census-%s.json", resourceId));
}
}
else if(resourceType.equals(ResourceType.List) &&
Expand All @@ -81,7 +81,7 @@ else if(resourceType.equals(ResourceType.List) &&
} else if(resourceType.equals(ResourceType.MeasureReport)
&& ((MeasureReport) resource).getType().equals(MeasureReport.MeasureReportType.SUBJECTLIST)) {
aggregateMeasureReports.add(e);
bundleEntryIndexToFileMap.put(index, String.format("aggregate-%s.json", id));
bundleEntryIndexToFileMap.put(index, String.format("aggregate-%s.json", resourceId));
} else if (patientReference != null) {
String patientId = patientReference.replace("Patient/", "");
if (!this.patientResources.containsKey(patientId)) {
Expand Down

0 comments on commit 71b5e67

Please sign in to comment.