Workaround ClinicalImpression definition problem in core spec

This commit is contained in:
Grahame Grieve 2023-07-20 08:20:18 +10:00
parent 38052a6e75
commit 274c49bde5
1 changed files with 20 additions and 1 deletions

View File

@ -26,8 +26,27 @@ public class StructureDefinitionHacker {
if (VersionUtilities.isR4Ver(version) && "http://hl7.org/fhir/StructureDefinition/example-composition".equals(sd.getUrl())) {
for (ElementDefinition ed : sd.getSnapshot().getElement()) {
fixDocSecURL(ed);
} for (ElementDefinition ed : sd.getDifferential().getElement()) {
}
for (ElementDefinition ed : sd.getDifferential().getElement()) {
fixDocSecURL(ed);
if ("ClinicalImpression.problem".equals(ed.getPath())) {
// work around a bidi problem
ed.setComment("e.g. The patient is a pregnant, has congestive heart failure, has an Adenocarcinoma, and is allergic to penicillin.");
}
}
}
if (VersionUtilities.isR4Ver(version) && "http://hl7.org/fhir/StructureDefinition/ClinicalImpression".equals(sd.getUrl())) {
for (ElementDefinition ed : sd.getSnapshot().getElement()) {
if ("ClinicalImpression.problem".equals(ed.getPath())) {
// work around a bidi problem
ed.setComment("e.g. The patient is a pregnant, has congestive heart failure, has an Adenocarcinoma, and is allergic to penicillin.");
}
}
for (ElementDefinition ed : sd.getDifferential().getElement()) {
if ("ClinicalImpression.problem".equals(ed.getPath())) {
// work around a bidi problem
ed.setComment("e.g. The patient is a pregnant, has congestive heart failure, has an Adenocarcinoma, and is allergic to penicillin.");
}
}
}
return sd;