Template:CDA Document: Difference between revisions

From IHE Wiki
Jump to navigation Jump to search
Kboone (talk | contribs)
mNo edit summary
Kboone (talk | contribs)
mNo edit summary
Line 66: Line 66:
{{If|test={{{5|{{{LOINC|}}}}}}|then=
{{If|test={{{5|{{{LOINC|}}}}}}|then=
===== Schematron =====
===== Schematron =====
  <pattern name='Template_{{{2}}}'>
<tt>
    <rule context='*[templateId/@root="{{{2}}}"]'>
<pattern name='Template_{{{2}}}'>
      <!-- Verify that the template id is used on the appropriate type of object -->
:<rule context='*[templateId/@root="{{{2}}}"]'>
      <assert test='../cda:ClinicalDocument'>
::<!-- Verify that the template id is used on the appropriate type of object -->
        Error: The {{{1}}} can only be used on Clinical Documents.
::<assert test='../cda:ClinicalDocument'>
      </assert>{{If|test={{{Parent|}}}|then=
:::Error: The {{{1}}} can only be used on Clinical Documents.
      <!-- Verify that the parent templateId is also present. -->
::</assert>{{If|test={{{Parent|}}}|then=
      <assert test='templateId[@root="{{{Parent}}}"]'>
::<!-- Verify that the parent templateId is also present. -->
        Error: The parent template identifier for medical summary is not present.
::<assert test='templateId[@root="{{{Parent}}}"]'>
      </assert>
:::Error: The parent template identifier for medical summary is not present.
::</assert>
}}}}{{If|test={{{LOINC|}}}|then=
}}}}{{If|test={{{LOINC|}}}|then=
      <!-- Verify the document type code -->
::<!-- Verify the document type code -->
      <assert test='code[@code = "{{{LOINC}}}"]'>
::<assert test='code[@code = "{{{LOINC}}}"]'>
        Error: The document type code of a {{{2}}} must be {{{LOINC}}}
:::Error: The document type code of a {{{2}}} must be {{{LOINC}}}
      </assert>
::</assert>
      <assert test='code[@codeSystem = "2.16.840.1.113883.6.1"]'>
::<assert test='code[@codeSystem = "2.16.840.1.113883.6.1"]'>
        Error: The document type code must come from the LOINC code  
:::Error: The document type code must come from the LOINC code  
        system (2.16.840.1.113883.6.1).
:::system (2.16.840.1.113883.6.1).
      </assert>
::</assert>
}}{{If|test={{{5|}}}|then={{Schematron Rule|{{{5}}}|{{{1}}}|{{{2}}}|{{{6}}}|{{{7}}}|{{{8}}}|{{{9}}}}}  
}}{{If|test={{{5|}}}|then={{Schematron Rule|{{{5}}}|{{{1}}}|{{{2}}}|{{{6}}}|{{{7}}}|{{{8}}}|{{{9}}}}}  
}}{{If|test={{{10|}}}|then={{Schematron Rule|{{{10}}}|{{{1}}}|{{{2}}}|{{{11}}}|{{{12}}}|{{{13}}}|{{{14}}}}}  
}}{{If|test={{{10|}}}|then={{Schematron Rule|{{{10}}}|{{{1}}}|{{{2}}}|{{{11}}}|{{{12}}}|{{{13}}}|{{{14}}}}}  
Line 125: Line 126:
}}{{If|test={{{195|}}}|then={{Schematron Rule|{{{195}}}|{{{1}}}|{{{2}}}|{{{196}}}|{{{197}}}|{{{198}}}|{{{199}}}}}  
}}{{If|test={{{195|}}}|then={{Schematron Rule|{{{195}}}|{{{1}}}|{{{2}}}|{{{196}}}|{{{197}}}|{{{198}}}|{{{199}}}}}  
}}{{If|test={{{5|{{{LOINC|}}}}}}|then=
}}{{If|test={{{5|{{{LOINC|}}}}}}|then=
    </rule>
:</rule>
  </pattern>
</pattern>
</tt>
}}
}}



Revision as of 16:48, 18 May 2007

{{{1}}} Specification {{{2}}}