hl7au / au-fhir-base

AU Base FHIR Implementation Guide Source
35 stars 26 forks source link

Template: Autogenerated extension page contexts are wrong #761

Closed robeastwood-agency closed 1 year ago

robeastwood-agency commented 1 year ago

In the current build of AU Base, all extensions have an automatic rendering (ie from the template and not markdown) of their context, starting with the text

This extension may be used on the following element(s):

In each case though it then just renders Element ID for all instead of the actual element path.

Eg Extension: Date of Arrival in Australia has image

But it should be

  • Patient
  • RelatedPerson
  • Practitioner

Note that the static 4.1.0-ballot IG shows the correct context.

This needs further investigation to determine whether this is a upstream template/publisher issue or (given that it works in the 4.1.0-ballot snapshot) something to do with HL7AU IG.

robeastwood-agency commented 1 year ago

Note re versions of IG publisher - ballot snapshot was built with v1.2.14 and current build v1.2.25

robeastwood-agency commented 1 year ago

According to this zulip thread, it was a template issue (HL7 base IG template), since fixed by Lloyd McKenzie on Dec 9 2022 by this commit to the template file layouts/layout-ext.html.

The HL7AU IG template chain is:

Templates: hl7.au.fhir.template#current -> hl7.au.base.template#current -> fhir.base.template#current

And the HL7AU hl7.au.base.template also includes the file layouts/layout-ext.html (thereby overriding the upstream one) which has the original pre-Lloyd fix code (line 23):

    <ul>
        {% for context in site.data.structuredefinitions['{{[id]}}'].contexts %}
        <li>{{context.type}}</li>
        {% endfor %}
    </ul>

Therefore, my conclusion is that this is a HL7AU template issue.

I'll raise a ticket on hl7au/hl7.au.base.template

robeastwood-agency commented 1 year ago

Created issue: https://github.com/hl7au/hl7.au.base.template/issues/1

robeastwood-agency commented 1 year ago

This has been fixed via commit hl7au/hl7.au.base.template@0f4d8a9e

Rebuild of HL7AU IG shows expected content.