HL7 FHIR Implementation Guide: Sri Lanka
0.1.0 - STU1

HL7 FHIR Implementation Guide: Sri Lanka, published by Jembi Health Systems. This is not an authorized publication; it is the continuous build for version 0.1.0. This version is based on the current content of https://github.com/jembi/Sri-Lanka and changes regularly. See the Directory of published versions

## : null - JSON Representation

Draft as of 2023-11-10

Raw json | Download

    {
      "resourceType" : "StructureMap",
      "id" : "HIMSRiskBehaviourQRToLM-PhysicalActivity",
      "text" : {
        "status" : "generated",
        "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><pre class=\"fml\">\r\n<b>map</b><span style=\"color: navy\"> &quot;</span>http://openhie.org/fhir/sri-lanka/StructureMap/HIMSRiskBehaviourQRToLM-PhysicalActivity<span style=\"color: navy\">&quot; = &quot;</span>HIMSRiskBehaviourQRToLM-PhysicalActivity<span style=\"color: navy\">&quot;\r\n\r\n</span><span style=\"color: navy\">// </span><span style=\"color: green\">Maps the Risk Behaviour Questionnaire Response to the HIMS Logical Model data elements.</span>\r\n\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span><a href=\"http://hl7.org/fhir/R4/questionnaireresponse.html\" title=\"QuestionnaireResponse\">http://hl7.org/fhir/StructureDefinition/QuestionnaireResponse</a><span style=\"color: navy\">&quot; </span><b>alias </b>QResp <b>as </b><b>source</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span><a href=\"StructureDefinition-HIMSRiskBehaviourDataDictionary.html\" title=\"HIMS Risk Behaviour\">http://openhie.org/fhir/sri-lanka/StructureDefinition/HIMSRiskBehaviourDataDictionary</a><span style=\"color: navy\">&quot; </span><b>alias </b>IMMZC <b>as </b><b>target</b>\r\n\r\n<b>group </b>QRespToIMMZC<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">qr</span><span style=\"color: navy\"> : </span>QResp, <b>target</b> <span style=\"color: maroon\">immzc</span><span style=\"color: navy\"> : </span>IMMZC<span style=\"color: navy\">)</span><span style=\"color: navy\"> {\r\n</span>  qr.item<b> as </b><span style=\"color: maroon\">item</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    item.answer first<b> as </b><span style=\"color: maroon\">answer</span><b> where </b>item.linkId = 'physicalActivity'<b> then</b><span style=\"color: navy\"> {\r\n</span>      answer.value<b> as </b><span style=\"color: maroon\">coding</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        coding.code<b> as </b><span style=\"color: maroon\">content</span><span style=\"color: navy\"><b> -&gt; </b></span>immzc.physicalActivity = <span style=\"color: maroon\">content</span> <i>&quot;SetPhysicalActivity&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;ProcessCoding&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;FirstAnswerForPhysicalActivity&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;processItems&quot;</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span></pre></div>"
      },
      "url" : "http://openhie.org/fhir/sri-lanka/StructureMap/HIMSRiskBehaviourQRToLM-PhysicalActivity",
      "version" : "0.1.0",
      "name" : "HIMSRiskBehaviourQRToLM-PhysicalActivity",
      "status" : "draft",
      "date" : "2023-11-10T04:37:53+00:00",
      "publisher" : "Jembi Health Systems",
      "contact" : [
        {
          "name" : "Jembi Health Systems",
          "telecom" : [
            {
              "system" : "url",
              "value" : "https://www.jembi.org"
            },
            {
              "system" : "email",
              "value" : "info@jembi.org"
            }
          ]
        },
        {
          "name" : "Richard Langford",
          "telecom" : [
            {
              "system" : "email",
              "value" : "richard.langford@jembi.org",
              "use" : "work"
            }
          ]
        }
      ],
      "description" : "Maps the Risk Behaviour Questionnaire Response to the HIMS Logical Model data elements.",
      "jurisdiction" : [
        {
          "coding" : [
            {
              "system" : "http://unstats.un.org/unsd/methods/m49/m49.htm",
              "code" : "001",
              "display" : "World"
            }
          ]
        }
      ],
      "structure" : [
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/QuestionnaireResponse",
          "mode" : "source",
          "alias" : "QResp"
        },
        {
          "url" : "http://openhie.org/fhir/sri-lanka/StructureDefinition/HIMSRiskBehaviourDataDictionary",
          "mode" : "target",
          "alias" : "IMMZC"
        }
      ],
      "group" : [
        {
          "name" : "QRespToIMMZC",
          "typeMode" : "none",
          "input" : [
            {
              "name" : "qr",
              "type" : "QResp",
              "mode" : "source"
            },
            {
              "name" : "immzc",
              "type" : "IMMZC",
              "mode" : "target"
            }
          ],
          "rule" : [
            {
              "name" : "processItems",
              "source" : [
                {
                  "context" : "qr",
                  "element" : "item",
                  "variable" : "item"
                }
              ],
              "rule" : [
                {
                  "name" : "FirstAnswerForPhysicalActivity",
                  "source" : [
                    {
                      "context" : "item",
                      "element" : "answer",
                      "listMode" : "first",
                      "variable" : "answer",
                      "condition" : "item.linkId = 'physicalActivity'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "ProcessCoding",
                      "source" : [
                        {
                          "context" : "answer",
                          "element" : "value",
                          "variable" : "coding"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetPhysicalActivity",
                          "source" : [
                            {
                              "context" : "coding",
                              "element" : "code",
                              "variable" : "content"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "immzc",
                              "contextType" : "variable",
                              "element" : "physicalActivity",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueId" : "content"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    }