Stream: implementers
Topic: Narrative html
Marc Riding (Sep 18 2018 at 12:04):
Hi Guys,
When creating a fhir bundle (will be using Ewout Kramer's .net libs)
Couple of questions if anyone can help.
1. So the html in the narrative/text section of resource, do we create it all ourselves ? even the parts marked as generated ?
And I am guessing if we have a referenced "sub-element" that itself contains html, then this child's narrative should not be included in the parent.
So In our scenario we have an medications section which is a slice within CareConnect-ITK-MH-Composition-1 (https://fhir.nhs.uk/STU3/StructureDefinition/CareConnect-ITK-MH-Composition-1) The medication slice must have a CareConnect-ITK-Medication-List-1 nested/referenced inside it. The list contains individual medication resources (CareConnect-ITK-MedicationStatement-1)
The medications slice obviously has a text element. Should this contain html representation of all medications ? Or do we just place only the header text in here, and allow the children of CareConnect-ITK-Medication-List-1 to carry the text/html for each medication.
2. Can anyone advise how this html can be rendered into a single document ? do we write our own xsl or equivalent ? - We need to render a copy before we send the bundle to GP
Thanks for any help/advice, sorry if its a noob question, I'm just starting out with fhir.
Marc
Lloyd McKenzie (Sep 18 2018 at 14:50):
1. You can't mark parts as generated. Either the whole narrative for the resource is generated or it's marked as 'additional'. If you have a 'Reference' element, you'll typically include just a little bit about it, but not the full narrative of the target resource. For example, you might mention the patient or Practititoner's name, but not the demographics and other contact information you would typically include to fully render the patient or practitioner. (Note that the Composition.section can have text that overrides the narrative - this is typically used to include a view of the narrative that ommits shared context that applies to the document as a whole - so that every procedure, observation, etc. in the document doesn't repeat the patient's name.)
2. There's a standard transform that'll take a document Bundle and concatenate the approrpriate narratives to create an HTML rendering of the document in the XML Tools reference implementation (grab the one for the version of FHIR you're using).
Last updated: Apr 12 2022 at 19:14 UTC