diff --git a/docker/service/src/main/java/uk/nhs/adaptors/scr/mappings/from/fhir/CompositionMapper.java b/docker/service/src/main/java/uk/nhs/adaptors/scr/mappings/from/fhir/CompositionMapper.java index 4921115a4..cd77c9a89 100644 --- a/docker/service/src/main/java/uk/nhs/adaptors/scr/mappings/from/fhir/CompositionMapper.java +++ b/docker/service/src/main/java/uk/nhs/adaptors/scr/mappings/from/fhir/CompositionMapper.java @@ -138,13 +138,6 @@ private static void setPresentation(GpSummary gpSummary, Composition composition removeEmptyNodes(divDocument); var divChildNodes = divDocument.getDocumentElement().getChildNodes(); for (int i = 0; i < divChildNodes.getLength(); i++) { - String toReplaceWith = divChildNodes.item(i).getTextContent(); - - // There has previously been incorrect verbiage in some SCRs. This helps to standardise language. - if (toReplaceWith.contains("One or more entries have been deliberately withheld from this GP Summary.")) { - toReplaceWith = toReplaceWith.replace("deliberately withheld", "intentionally withheld"); - divChildNodes.item(i).setTextContent(toReplaceWith); - } bodyNode.appendChild(htmlDocument.importNode(divChildNodes.item(i), true)); } } diff --git a/docker/service/src/main/java/uk/nhs/adaptors/scr/mappings/from/hl7/HtmlParser.java b/docker/service/src/main/java/uk/nhs/adaptors/scr/mappings/from/hl7/HtmlParser.java index 2a2790a3b..d95bcc667 100644 --- a/docker/service/src/main/java/uk/nhs/adaptors/scr/mappings/from/hl7/HtmlParser.java +++ b/docker/service/src/main/java/uk/nhs/adaptors/scr/mappings/from/hl7/HtmlParser.java @@ -127,15 +127,6 @@ private static Composition.SectionComponent buildSectionComponent(ParsedHtml par .addCoding(new Coding() .setCode(parsedHtml.h2Id))); } - String toBeReplaced = sectionComponent.getText().getDiv().getValue(); - - if (toBeReplaced.contains("One or more entries have been deliberately withheld from this GP Summary.")) { - toBeReplaced = toBeReplaced.replace( - "One or more entries have been deliberately withheld from this GP Summary.", - "One or more entries have been withheld from this GP Summary."); - sectionComponent.getText().getDiv().setValue(toBeReplaced); - } - return sectionComponent; } diff --git a/docker/service/src/test/resources/gp_summary/from/fhir/additional_information_gp_summary_1_presentation_text_value.html b/docker/service/src/test/resources/gp_summary/from/fhir/additional_information_gp_summary_1_presentation_text_value.html index 6896a9bee..915c641ab 100644 --- a/docker/service/src/test/resources/gp_summary/from/fhir/additional_information_gp_summary_1_presentation_text_value.html +++ b/docker/service/src/test/resources/gp_summary/from/fhir/additional_information_gp_summary_1_presentation_text_value.html @@ -3,7 +3,7 @@

General Practice Summary

Sourced from the patient's General Practice record. This summary may not include all the information pertinent to this patient.

Summary Created: 30 Apr 2020 16:13

-

One or more entries have been intentionally withheld from this GP Summary.

+

One or more entries have been deliberately withheld from this GP Summary.

Created by: WILSON, Bob (Mr)

Spine Testing, The Practice, Woodvale Terrace, Horsforth, Leeds LS18 4JW

Allergies and Adverse Reactions

@@ -316,7 +316,7 @@

Treatments

Social and Personal Circumstances

-

One or more entries have been intentionally withheld from this GP Summary.

+

One or more entries have been deliberately withheld from this GP Summary.

diff --git a/docker/service/src/test/resources/gp_summary/partials/additional_information_gp_summary_1_composition.json b/docker/service/src/test/resources/gp_summary/partials/additional_information_gp_summary_1_composition.json index 51d222657..c35a2118e 100644 --- a/docker/service/src/test/resources/gp_summary/partials/additional_information_gp_summary_1_composition.json +++ b/docker/service/src/test/resources/gp_summary/partials/additional_information_gp_summary_1_composition.json @@ -55,7 +55,7 @@ }, "text": { "status": "generated", - "div": "

Sourced from the patient's General Practice record. This summary may not include all the information pertinent to this patient.

Summary Created: 30 Apr 2020 16:13

One or more entries have been withheld from this GP Summary.

Created by: WILSON, Bob (Mr)

Spine Testing, The Practice, Woodvale Terrace, Horsforth, Leeds LS18 4JW

" + "div": "

Sourced from the patient's General Practice record. This summary may not include all the information pertinent to this patient.

Summary Created: 30 Apr 2020 16:13

One or more entries have been deliberately withheld from this GP Summary.

Created by: WILSON, Bob (Mr)

Spine Testing, The Practice, Woodvale Terrace, Horsforth, Leeds LS18 4JW

" } }, { @@ -181,7 +181,7 @@ }, "text": { "status": "generated", - "div": "

One or more entries have been withheld from this GP Summary.

DateDescriptionValueSupporting Information
01 Apr 2020Main spoken language EnglishBilingual
31 Mar 2020Main spoken language English[No notes were originally recorded]
26 Mar 2020Main spoken language Mandarin

Summary Sent: 30 Apr 2020 16:13

" + "div": "

One or more entries have been deliberately withheld from this GP Summary.

DateDescriptionValueSupporting Information
01 Apr 2020Main spoken language EnglishBilingual
31 Mar 2020Main spoken language English[No notes were originally recorded]
26 Mar 2020Main spoken language Mandarin

Summary Sent: 30 Apr 2020 16:13

" } } ] diff --git a/docker/service/src/test/resources/html_parser/example_withheld.json b/docker/service/src/test/resources/html_parser/example_withheld.json index e3fed7bf3..5b28e0965 100644 --- a/docker/service/src/test/resources/html_parser/example_withheld.json +++ b/docker/service/src/test/resources/html_parser/example_withheld.json @@ -9,7 +9,7 @@ }, "text": { "status": "generated", - "div": "

Sourced from the patient's General Practice record. This summary may not include all the information pertinent to this patient.

Summary Created: 30 Apr 2020 16:13

One or more entries have been withheld from this GP Summary.

Created by: WILSON, Bob (Mr)

Spine Testing, The Practice, Woodvale Terrace, Horsforth, Leeds LS18 4JW

" + "div": "

Sourced from the patient's General Practice record. This summary may not include all the information pertinent to this patient.

Summary Created: 30 Apr 2020 16:13

One or more entries have been deliberately withheld from this GP Summary.

Created by: WILSON, Bob (Mr)

Spine Testing, The Practice, Woodvale Terrace, Horsforth, Leeds LS18 4JW

" } }, { "title": "Allergies and Adverse Reactions", @@ -108,7 +108,7 @@ }, "text": { "status": "generated", - "div": "

One or more entries have been withheld from this GP Summary.

DateDescriptionValueSupporting Information
01 Apr 2020Main spoken language EnglishBilingual
31 Mar 2020Main spoken language English[No notes were originally recorded]
26 Mar 2020Main spoken language Mandarin

Summary Sent: 30 Apr 2020 16:13

" + "div": "

One or more entries have been deliberately withheld from this GP Summary.

DateDescriptionValueSupporting Information
01 Apr 2020Main spoken language EnglishBilingual
31 Mar 2020Main spoken language English[No notes were originally recorded]
26 Mar 2020Main spoken language Mandarin

Summary Sent: 30 Apr 2020 16:13

" } } ] -} \ No newline at end of file +}