WHO Clinical Care in Crisis Implementation Guide for Children
0.1.0 - ci-build

WHO Clinical Care in Crisis Implementation Guide for Children - Local Development build (v0.1.0). See the Directory of published versions

: che.b18-21.symptoms.2.m.m - JSON Representation

Active as of 2023-10-04

Raw json | Download


{
  "resourceType" : "StructureMap",
  "id" : "che.b18-21.symptoms.2.m.m",
  "text" : {
    "status" : "generated",
    "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><pre>map &quot;https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureMap/che.b18-21.symptoms.2.m.m&quot; = &quot;che.b18-21.symptoms.2.m.m&quot;\r\n\r\n\r\nuses &quot;http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaireresponse&quot; alias 'questionnaireResponse' as source\r\nuses &quot;http://hl7.org/fhir/StructureDefinition/Bundle&quot; alias 'Bundle' as target\r\nuses &quot;https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/observation&quot; alias 'Observation' as target\r\nuses &quot;https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/cheobservation&quot; alias 'CHE Observation' as produced\r\n\r\ngroup bundletrans(source src : questionnaireResponse, target bundle : Bundle) {\r\n  src -&gt; bundle.id = uuid() &quot;id&quot;;\r\n  src -&gt; bundle.type = 'batch' &quot;type&quot;;\r\n  src.item first as item where (linkId = 'CHE.B18S1.DE01') and answer.exists() then {\r\n    src -&gt; bundle.entry as entry then {\r\n      src -&gt;  entry.request as request,  request.method = 'POST',  uuid() as uuid,  request.url = append('/Observation/', uuid) &quot;b50ac4c5&quot;;\r\n      src -&gt; entry.resource = create('Observation') as tgt then {\r\n        src -&gt; tgt then cheobservationcheb18s1de01(src, tgt) &quot;5e49130c&quot;;\r\n      } &quot;eea1a6cc&quot;;\r\n    } &quot;7f0a73b3&quot;;\r\n  } &quot;01ea87d4&quot;;\r\n  src.item first as item where (linkId = 'CHE.B18S1.DE02') and answer.exists() then {\r\n    src -&gt; bundle.entry as entry then {\r\n      src -&gt;  entry.request as request,  request.method = 'POST',  uuid() as uuid,  request.url = append('/Observation/', uuid) &quot;b50ac4c5&quot;;\r\n      src -&gt; entry.resource = create('Observation') as tgt then {\r\n        src -&gt; tgt then cheobservationcheb18s1de02(src, tgt) &quot;20dbebf1&quot;;\r\n      } &quot;2d4075a6&quot;;\r\n    } &quot;7352763e&quot;;\r\n  } &quot;c5a4deac&quot;;\r\n  src.item first as item where (linkId = 'CHE.B20S1.DE01') and answer.exists() then {\r\n    src -&gt; bundle.entry as entry then {\r\n      src -&gt;  entry.request as request,  request.method = 'POST',  uuid() as uuid,  request.url = append('/Observation/', uuid) &quot;b50ac4c5&quot;;\r\n      src -&gt; entry.resource = create('Observation') as tgt then {\r\n        src -&gt; tgt then cheobservationcheb20s1de01(src, tgt) &quot;05e882b8&quot;;\r\n      } &quot;36be9489&quot;;\r\n    } &quot;e25ec330&quot;;\r\n  } &quot;cb79e0f5&quot;;\r\n  src.item first as item where (linkId = 'CHE.B21S1.DE06') and answer.exists() then {\r\n    src -&gt; bundle.entry as entry then {\r\n      src -&gt;  entry.request as request,  request.method = 'POST',  uuid() as uuid,  request.url = append('/Observation/', uuid) &quot;b50ac4c5&quot;;\r\n      src -&gt; entry.resource = create('Observation') as tgt then {\r\n        src -&gt; tgt then cheobservationcheb21s1de06(src, tgt) &quot;a66e1c8d&quot;;\r\n      } &quot;4e2a4718&quot;;\r\n    } &quot;6ff871d2&quot;;\r\n  } &quot;1f7a68c1&quot;;\r\n}\r\n\r\ngroup cheobservationcheb18s1de01(source src, target tgt) {\r\n  src -&gt;  tgt.identifier = create('Identifier') as CodeID,  CodeID.system = 'http://hl7.org/fhir/namingsystem-identifier-type',  CodeID.use = 'official',  CodeID.value = 'uuid',  CodeID.id = uuid() &quot;id-cheb18s1de01&quot;;\r\n  src.encounter as encounter -&gt; tgt.encounter = encounter &quot;35bc6b82&quot;;\r\n  src.subject as subject -&gt;  tgt.subject = subject,  tgt.meta = create('Meta') as newMeta,  newMeta.profile = 'https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/cheobservation',  tgt.code = create('CodeableConcept') as concept,  concept.coding = create('Coding') as coding,  coding.system = 'https://fhir.dk.swisstph-mis.ch/matchbox/fhir/CodeSystem/che-custom-codes',  coding.code = 'CHE.B18S1.DE01' &quot;code-cheb18s1de01&quot;;\r\n  src.item as itemtimestamp where linkId = 'timestamp' then {\r\n    itemtimestamp.answer first as atimestamp then {\r\n      atimestamp.value as val -&gt; tgt.issued = val &quot;5af77f2c&quot;;\r\n    } &quot;7f22f29f&quot;;\r\n  } &quot;aae7a11d&quot;;\r\n  src.subject as subject -&gt; tgt.subject = subject &quot;patient&quot;;\r\n  src.item first as item where (linkId = 'CHE.B18S1.DE01') and answer.exists() then {\r\n    item.answer first as a then {\r\n      a where a.value = true -&gt;  tgt.status = 'final',  tgt.value = true &quot;final-cheb18s1de01&quot;;\r\n      a where a.value = false -&gt;  tgt.status = 'cancelled',  tgt.value = false &quot;notfound-cheb18s1de01&quot;;\r\n    } &quot;bdab9370&quot;;\r\n  } &quot;8dd08e5d&quot;;\r\n}\r\n\r\ngroup cheobservationcheb18s1de02(source src, target tgt) {\r\n  src -&gt;  tgt.identifier = create('Identifier') as CodeID,  CodeID.system = 'http://hl7.org/fhir/namingsystem-identifier-type',  CodeID.use = 'official',  CodeID.value = 'uuid',  CodeID.id = uuid() &quot;id-cheb18s1de02&quot;;\r\n  src.encounter as encounter -&gt; tgt.encounter = encounter &quot;35bc6b82&quot;;\r\n  src.subject as subject -&gt;  tgt.subject = subject,  tgt.meta = create('Meta') as newMeta,  newMeta.profile = 'https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/cheobservation',  tgt.code = create('CodeableConcept') as concept,  concept.coding = create('Coding') as coding,  coding.system = 'https://fhir.dk.swisstph-mis.ch/matchbox/fhir/CodeSystem/che-custom-codes',  coding.code = 'CHE.B18S1.DE02' &quot;code-cheb18s1de02&quot;;\r\n  src.item as itemtimestamp where linkId = 'timestamp' then {\r\n    itemtimestamp.answer first as atimestamp then {\r\n      atimestamp.value as val -&gt; tgt.issued = val &quot;5af77f2c&quot;;\r\n    } &quot;7f22f29f&quot;;\r\n  } &quot;aae7a11d&quot;;\r\n  src.subject as subject -&gt; tgt.subject = subject &quot;patient&quot;;\r\n  src.item first as item where (linkId = 'CHE.B18S1.DE02') and answer.exists() then {\r\n    item.answer first as a then {\r\n      a.value as val then {\r\n        val where val.code = 'none' -&gt; tgt.status = 'cancelled' &quot;8ab1d7a5&quot;;\r\n        val where val.code != 'none' -&gt;  tgt.value = create('CodeableConcept') as cc,  cc.coding = val,  tgt.status = 'final' &quot;a1050460&quot;;\r\n      } &quot;4ca9082e&quot;;\r\n    } &quot;7c587a4b&quot;;\r\n  } &quot;f6147731&quot;;\r\n}\r\n\r\ngroup cheobservationcheb20s1de01(source src, target tgt) {\r\n  src -&gt;  tgt.identifier = create('Identifier') as CodeID,  CodeID.system = 'http://hl7.org/fhir/namingsystem-identifier-type',  CodeID.use = 'official',  CodeID.value = 'uuid',  CodeID.id = uuid() &quot;id-cheb20s1de01&quot;;\r\n  src.encounter as encounter -&gt; tgt.encounter = encounter &quot;35bc6b82&quot;;\r\n  src.subject as subject -&gt;  tgt.subject = subject,  tgt.meta = create('Meta') as newMeta,  newMeta.profile = 'https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/cheobservation',  tgt.code = create('CodeableConcept') as concept,  concept.coding = create('Coding') as coding,  coding.system = 'https://fhir.dk.swisstph-mis.ch/matchbox/fhir/CodeSystem/che-custom-codes',  coding.code = 'CHE.B20S1.DE01' &quot;code-cheb20s1de01&quot;;\r\n  src.item as itemtimestamp where linkId = 'timestamp' then {\r\n    itemtimestamp.answer first as atimestamp then {\r\n      atimestamp.value as val -&gt; tgt.issued = val &quot;5af77f2c&quot;;\r\n    } &quot;7f22f29f&quot;;\r\n  } &quot;aae7a11d&quot;;\r\n  src.subject as subject -&gt; tgt.subject = subject &quot;patient&quot;;\r\n  src.item first as item where (linkId = 'CHE.B20S1.DE01') and answer.exists() then {\r\n    item.answer first as a then {\r\n      a where a.value = true -&gt;  tgt.status = 'final',  tgt.value = true &quot;final-cheb20s1de01&quot;;\r\n      a where a.value = false -&gt;  tgt.status = 'cancelled',  tgt.value = false &quot;notfound-cheb20s1de01&quot;;\r\n    } &quot;bdab9370&quot;;\r\n  } &quot;fea7dc7e&quot;;\r\n}\r\n\r\ngroup cheobservationcheb21s1de06(source src, target tgt) {\r\n  src -&gt;  tgt.identifier = create('Identifier') as CodeID,  CodeID.system = 'http://hl7.org/fhir/namingsystem-identifier-type',  CodeID.use = 'official',  CodeID.value = 'uuid',  CodeID.id = uuid() &quot;id-cheb21s1de06&quot;;\r\n  src.encounter as encounter -&gt; tgt.encounter = encounter &quot;35bc6b82&quot;;\r\n  src.subject as subject -&gt;  tgt.subject = subject,  tgt.meta = create('Meta') as newMeta,  newMeta.profile = 'https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/cheobservation',  tgt.code = create('CodeableConcept') as concept,  concept.coding = create('Coding') as coding,  coding.system = 'https://fhir.dk.swisstph-mis.ch/matchbox/fhir/CodeSystem/che-custom-codes',  coding.code = 'CHE.B21S1.DE06' &quot;code-cheb21s1de06&quot;;\r\n  src.item as itemtimestamp where linkId = 'timestamp' then {\r\n    itemtimestamp.answer first as atimestamp then {\r\n      atimestamp.value as val -&gt; tgt.issued = val &quot;5af77f2c&quot;;\r\n    } &quot;7f22f29f&quot;;\r\n  } &quot;aae7a11d&quot;;\r\n  src.subject as subject -&gt; tgt.subject = subject &quot;patient&quot;;\r\n  src.item first as item where (linkId = 'CHE.B21S1.DE06') and answer.exists() then {\r\n    item.answer first as a then {\r\n      a where a.value = true -&gt;  tgt.status = 'final',  tgt.value = true &quot;final-cheb21s1de06&quot;;\r\n      a where a.value = false -&gt;  tgt.status = 'cancelled',  tgt.value = false &quot;notfound-cheb21s1de06&quot;;\r\n    } &quot;bdab9370&quot;;\r\n  } &quot;7b9a75da&quot;;\r\n}\r\n\r\n</pre></div>"
  },
  "url" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureMap/che.b18-21.symptoms.2.m.m",
  "version" : "0.1.0",
  "name" : "che.b18-21.symptoms.2.m.m",
  "status" : "active",
  "date" : "2023-10-04T12:32:21+00:00",
  "publisher" : "WHO",
  "contact" : [
    {
      "name" : "WHO",
      "telecom" : [
        {
          "system" : "url",
          "value" : "http://who.int"
        }
      ]
    }
  ],
  "structure" : [
    {
      "url" : "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaireresponse",
      "mode" : "source",
      "alias" : "'questionnaireResponse'"
    },
    {
      "url" : "http://hl7.org/fhir/StructureDefinition/Bundle",
      "mode" : "target",
      "alias" : "'Bundle'"
    },
    {
      "url" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/observation",
      "mode" : "target",
      "alias" : "'Observation'"
    },
    {
      "url" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/cheobservation",
      "mode" : "produced",
      "alias" : "'CHE Observation'"
    }
  ],
  "group" : [
    {
      "name" : "bundletrans",
      "typeMode" : "none",
      "input" : [
        {
          "name" : "src",
          "type" : "questionnaireResponse",
          "mode" : "source"
        },
        {
          "name" : "bundle",
          "type" : "Bundle",
          "mode" : "target"
        }
      ],
      "rule" : [
        {
          "name" : "id",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "bundle",
              "contextType" : "variable",
              "element" : "id",
              "transform" : "uuid"
            }
          ]
        },
        {
          "name" : "type",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "bundle",
              "contextType" : "variable",
              "element" : "type",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "batch"
                }
              ]
            }
          ]
        },
        {
          "name" : "01ea87d4",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "listMode" : "first",
              "variable" : "item",
              "condition" : "(linkId = 'CHE.B18S1.DE01') and answer.exists()"
            }
          ],
          "rule" : [
            {
              "name" : "7f0a73b3",
              "source" : [
                {
                  "context" : "src"
                }
              ],
              "target" : [
                {
                  "context" : "bundle",
                  "contextType" : "variable",
                  "element" : "entry",
                  "variable" : "entry"
                }
              ],
              "rule" : [
                {
                  "name" : "b50ac4c5",
                  "source" : [
                    {
                      "context" : "src"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "request",
                      "variable" : "request"
                    },
                    {
                      "context" : "request",
                      "contextType" : "variable",
                      "element" : "method",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "POST"
                        }
                      ]
                    },
                    {
                      "contextType" : "variable",
                      "variable" : "uuid",
                      "transform" : "uuid"
                    },
                    {
                      "context" : "request",
                      "contextType" : "variable",
                      "element" : "url",
                      "transform" : "append",
                      "parameter" : [
                        {
                          "valueString" : "/Observation/"
                        },
                        {
                          "valueId" : "uuid"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "eea1a6cc",
                  "source" : [
                    {
                      "context" : "src"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "resource",
                      "variable" : "tgt",
                      "transform" : "create",
                      "parameter" : [
                        {
                          "valueString" : "Observation"
                        }
                      ]
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "5e49130c",
                      "source" : [
                        {
                          "context" : "src"
                        }
                      ],
                      "target" : [
                        {
                          "contextType" : "variable",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueId" : "tgt"
                            }
                          ]
                        }
                      ],
                      "dependent" : [
                        {
                          "name" : "cheobservationcheb18s1de01",
                          "variable" : [
                            "src",
                            "tgt"
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "c5a4deac",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "listMode" : "first",
              "variable" : "item",
              "condition" : "(linkId = 'CHE.B18S1.DE02') and answer.exists()"
            }
          ],
          "rule" : [
            {
              "name" : "7352763e",
              "source" : [
                {
                  "context" : "src"
                }
              ],
              "target" : [
                {
                  "context" : "bundle",
                  "contextType" : "variable",
                  "element" : "entry",
                  "variable" : "entry"
                }
              ],
              "rule" : [
                {
                  "name" : "b50ac4c5",
                  "source" : [
                    {
                      "context" : "src"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "request",
                      "variable" : "request"
                    },
                    {
                      "context" : "request",
                      "contextType" : "variable",
                      "element" : "method",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "POST"
                        }
                      ]
                    },
                    {
                      "contextType" : "variable",
                      "variable" : "uuid",
                      "transform" : "uuid"
                    },
                    {
                      "context" : "request",
                      "contextType" : "variable",
                      "element" : "url",
                      "transform" : "append",
                      "parameter" : [
                        {
                          "valueString" : "/Observation/"
                        },
                        {
                          "valueId" : "uuid"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "2d4075a6",
                  "source" : [
                    {
                      "context" : "src"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "resource",
                      "variable" : "tgt",
                      "transform" : "create",
                      "parameter" : [
                        {
                          "valueString" : "Observation"
                        }
                      ]
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "20dbebf1",
                      "source" : [
                        {
                          "context" : "src"
                        }
                      ],
                      "target" : [
                        {
                          "contextType" : "variable",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueId" : "tgt"
                            }
                          ]
                        }
                      ],
                      "dependent" : [
                        {
                          "name" : "cheobservationcheb18s1de02",
                          "variable" : [
                            "src",
                            "tgt"
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "cb79e0f5",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "listMode" : "first",
              "variable" : "item",
              "condition" : "(linkId = 'CHE.B20S1.DE01') and answer.exists()"
            }
          ],
          "rule" : [
            {
              "name" : "e25ec330",
              "source" : [
                {
                  "context" : "src"
                }
              ],
              "target" : [
                {
                  "context" : "bundle",
                  "contextType" : "variable",
                  "element" : "entry",
                  "variable" : "entry"
                }
              ],
              "rule" : [
                {
                  "name" : "b50ac4c5",
                  "source" : [
                    {
                      "context" : "src"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "request",
                      "variable" : "request"
                    },
                    {
                      "context" : "request",
                      "contextType" : "variable",
                      "element" : "method",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "POST"
                        }
                      ]
                    },
                    {
                      "contextType" : "variable",
                      "variable" : "uuid",
                      "transform" : "uuid"
                    },
                    {
                      "context" : "request",
                      "contextType" : "variable",
                      "element" : "url",
                      "transform" : "append",
                      "parameter" : [
                        {
                          "valueString" : "/Observation/"
                        },
                        {
                          "valueId" : "uuid"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "36be9489",
                  "source" : [
                    {
                      "context" : "src"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "resource",
                      "variable" : "tgt",
                      "transform" : "create",
                      "parameter" : [
                        {
                          "valueString" : "Observation"
                        }
                      ]
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "05e882b8",
                      "source" : [
                        {
                          "context" : "src"
                        }
                      ],
                      "target" : [
                        {
                          "contextType" : "variable",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueId" : "tgt"
                            }
                          ]
                        }
                      ],
                      "dependent" : [
                        {
                          "name" : "cheobservationcheb20s1de01",
                          "variable" : [
                            "src",
                            "tgt"
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "1f7a68c1",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "listMode" : "first",
              "variable" : "item",
              "condition" : "(linkId = 'CHE.B21S1.DE06') and answer.exists()"
            }
          ],
          "rule" : [
            {
              "name" : "6ff871d2",
              "source" : [
                {
                  "context" : "src"
                }
              ],
              "target" : [
                {
                  "context" : "bundle",
                  "contextType" : "variable",
                  "element" : "entry",
                  "variable" : "entry"
                }
              ],
              "rule" : [
                {
                  "name" : "b50ac4c5",
                  "source" : [
                    {
                      "context" : "src"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "request",
                      "variable" : "request"
                    },
                    {
                      "context" : "request",
                      "contextType" : "variable",
                      "element" : "method",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "POST"
                        }
                      ]
                    },
                    {
                      "contextType" : "variable",
                      "variable" : "uuid",
                      "transform" : "uuid"
                    },
                    {
                      "context" : "request",
                      "contextType" : "variable",
                      "element" : "url",
                      "transform" : "append",
                      "parameter" : [
                        {
                          "valueString" : "/Observation/"
                        },
                        {
                          "valueId" : "uuid"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "4e2a4718",
                  "source" : [
                    {
                      "context" : "src"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "resource",
                      "variable" : "tgt",
                      "transform" : "create",
                      "parameter" : [
                        {
                          "valueString" : "Observation"
                        }
                      ]
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "a66e1c8d",
                      "source" : [
                        {
                          "context" : "src"
                        }
                      ],
                      "target" : [
                        {
                          "contextType" : "variable",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueId" : "tgt"
                            }
                          ]
                        }
                      ],
                      "dependent" : [
                        {
                          "name" : "cheobservationcheb21s1de06",
                          "variable" : [
                            "src",
                            "tgt"
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    },
    {
      "name" : "cheobservationcheb18s1de01",
      "typeMode" : "none",
      "input" : [
        {
          "name" : "src",
          "mode" : "source"
        },
        {
          "name" : "tgt",
          "mode" : "target"
        }
      ],
      "rule" : [
        {
          "name" : "id-cheb18s1de01",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "identifier",
              "variable" : "CodeID",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Identifier"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "system",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "http://hl7.org/fhir/namingsystem-identifier-type"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "use",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "official"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "value",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "uuid"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "id",
              "transform" : "uuid"
            }
          ]
        },
        {
          "name" : "35bc6b82",
          "source" : [
            {
              "context" : "src",
              "element" : "encounter",
              "variable" : "encounter"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "encounter",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "encounter"
                }
              ]
            }
          ]
        },
        {
          "name" : "code-cheb18s1de01",
          "source" : [
            {
              "context" : "src",
              "element" : "subject",
              "variable" : "subject"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "subject",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "subject"
                }
              ]
            },
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "meta",
              "variable" : "newMeta",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Meta"
                }
              ]
            },
            {
              "context" : "newMeta",
              "contextType" : "variable",
              "element" : "profile",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/cheobservation"
                }
              ]
            },
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "code",
              "variable" : "concept",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "CodeableConcept"
                }
              ]
            },
            {
              "context" : "concept",
              "contextType" : "variable",
              "element" : "coding",
              "variable" : "coding",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Coding"
                }
              ]
            },
            {
              "context" : "coding",
              "contextType" : "variable",
              "element" : "system",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/CodeSystem/che-custom-codes"
                }
              ]
            },
            {
              "context" : "coding",
              "contextType" : "variable",
              "element" : "code",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "CHE.B18S1.DE01"
                }
              ]
            }
          ]
        },
        {
          "name" : "aae7a11d",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "variable" : "itemtimestamp",
              "condition" : "linkId = 'timestamp'"
            }
          ],
          "rule" : [
            {
              "name" : "7f22f29f",
              "source" : [
                {
                  "context" : "itemtimestamp",
                  "element" : "answer",
                  "listMode" : "first",
                  "variable" : "atimestamp"
                }
              ],
              "rule" : [
                {
                  "name" : "5af77f2c",
                  "source" : [
                    {
                      "context" : "atimestamp",
                      "element" : "value",
                      "variable" : "val"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "issued",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "val"
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "patient",
          "source" : [
            {
              "context" : "src",
              "element" : "subject",
              "variable" : "subject"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "subject",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "subject"
                }
              ]
            }
          ]
        },
        {
          "name" : "8dd08e5d",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "listMode" : "first",
              "variable" : "item",
              "condition" : "(linkId = 'CHE.B18S1.DE01') and answer.exists()"
            }
          ],
          "rule" : [
            {
              "name" : "bdab9370",
              "source" : [
                {
                  "context" : "item",
                  "element" : "answer",
                  "listMode" : "first",
                  "variable" : "a"
                }
              ],
              "rule" : [
                {
                  "name" : "final-cheb18s1de01",
                  "source" : [
                    {
                      "context" : "a",
                      "condition" : "a.value = true"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "status",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "final"
                        }
                      ]
                    },
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "value",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueBoolean" : true
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "notfound-cheb18s1de01",
                  "source" : [
                    {
                      "context" : "a",
                      "condition" : "a.value = false"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "status",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "cancelled"
                        }
                      ]
                    },
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "value",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueBoolean" : false
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    },
    {
      "name" : "cheobservationcheb18s1de02",
      "typeMode" : "none",
      "input" : [
        {
          "name" : "src",
          "mode" : "source"
        },
        {
          "name" : "tgt",
          "mode" : "target"
        }
      ],
      "rule" : [
        {
          "name" : "id-cheb18s1de02",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "identifier",
              "variable" : "CodeID",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Identifier"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "system",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "http://hl7.org/fhir/namingsystem-identifier-type"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "use",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "official"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "value",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "uuid"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "id",
              "transform" : "uuid"
            }
          ]
        },
        {
          "name" : "35bc6b82",
          "source" : [
            {
              "context" : "src",
              "element" : "encounter",
              "variable" : "encounter"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "encounter",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "encounter"
                }
              ]
            }
          ]
        },
        {
          "name" : "code-cheb18s1de02",
          "source" : [
            {
              "context" : "src",
              "element" : "subject",
              "variable" : "subject"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "subject",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "subject"
                }
              ]
            },
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "meta",
              "variable" : "newMeta",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Meta"
                }
              ]
            },
            {
              "context" : "newMeta",
              "contextType" : "variable",
              "element" : "profile",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/cheobservation"
                }
              ]
            },
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "code",
              "variable" : "concept",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "CodeableConcept"
                }
              ]
            },
            {
              "context" : "concept",
              "contextType" : "variable",
              "element" : "coding",
              "variable" : "coding",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Coding"
                }
              ]
            },
            {
              "context" : "coding",
              "contextType" : "variable",
              "element" : "system",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/CodeSystem/che-custom-codes"
                }
              ]
            },
            {
              "context" : "coding",
              "contextType" : "variable",
              "element" : "code",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "CHE.B18S1.DE02"
                }
              ]
            }
          ]
        },
        {
          "name" : "aae7a11d",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "variable" : "itemtimestamp",
              "condition" : "linkId = 'timestamp'"
            }
          ],
          "rule" : [
            {
              "name" : "7f22f29f",
              "source" : [
                {
                  "context" : "itemtimestamp",
                  "element" : "answer",
                  "listMode" : "first",
                  "variable" : "atimestamp"
                }
              ],
              "rule" : [
                {
                  "name" : "5af77f2c",
                  "source" : [
                    {
                      "context" : "atimestamp",
                      "element" : "value",
                      "variable" : "val"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "issued",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "val"
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "patient",
          "source" : [
            {
              "context" : "src",
              "element" : "subject",
              "variable" : "subject"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "subject",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "subject"
                }
              ]
            }
          ]
        },
        {
          "name" : "f6147731",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "listMode" : "first",
              "variable" : "item",
              "condition" : "(linkId = 'CHE.B18S1.DE02') and answer.exists()"
            }
          ],
          "rule" : [
            {
              "name" : "7c587a4b",
              "source" : [
                {
                  "context" : "item",
                  "element" : "answer",
                  "listMode" : "first",
                  "variable" : "a"
                }
              ],
              "rule" : [
                {
                  "name" : "4ca9082e",
                  "source" : [
                    {
                      "context" : "a",
                      "element" : "value",
                      "variable" : "val"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "8ab1d7a5",
                      "source" : [
                        {
                          "context" : "val",
                          "condition" : "val.code = 'none'"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "tgt",
                          "contextType" : "variable",
                          "element" : "status",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueString" : "cancelled"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name" : "a1050460",
                      "source" : [
                        {
                          "context" : "val",
                          "condition" : "val.code != 'none'"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "tgt",
                          "contextType" : "variable",
                          "element" : "value",
                          "variable" : "cc",
                          "transform" : "create",
                          "parameter" : [
                            {
                              "valueString" : "CodeableConcept"
                            }
                          ]
                        },
                        {
                          "context" : "cc",
                          "contextType" : "variable",
                          "element" : "coding",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueId" : "val"
                            }
                          ]
                        },
                        {
                          "context" : "tgt",
                          "contextType" : "variable",
                          "element" : "status",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueString" : "final"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    },
    {
      "name" : "cheobservationcheb20s1de01",
      "typeMode" : "none",
      "input" : [
        {
          "name" : "src",
          "mode" : "source"
        },
        {
          "name" : "tgt",
          "mode" : "target"
        }
      ],
      "rule" : [
        {
          "name" : "id-cheb20s1de01",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "identifier",
              "variable" : "CodeID",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Identifier"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "system",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "http://hl7.org/fhir/namingsystem-identifier-type"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "use",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "official"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "value",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "uuid"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "id",
              "transform" : "uuid"
            }
          ]
        },
        {
          "name" : "35bc6b82",
          "source" : [
            {
              "context" : "src",
              "element" : "encounter",
              "variable" : "encounter"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "encounter",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "encounter"
                }
              ]
            }
          ]
        },
        {
          "name" : "code-cheb20s1de01",
          "source" : [
            {
              "context" : "src",
              "element" : "subject",
              "variable" : "subject"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "subject",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "subject"
                }
              ]
            },
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "meta",
              "variable" : "newMeta",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Meta"
                }
              ]
            },
            {
              "context" : "newMeta",
              "contextType" : "variable",
              "element" : "profile",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/cheobservation"
                }
              ]
            },
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "code",
              "variable" : "concept",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "CodeableConcept"
                }
              ]
            },
            {
              "context" : "concept",
              "contextType" : "variable",
              "element" : "coding",
              "variable" : "coding",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Coding"
                }
              ]
            },
            {
              "context" : "coding",
              "contextType" : "variable",
              "element" : "system",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/CodeSystem/che-custom-codes"
                }
              ]
            },
            {
              "context" : "coding",
              "contextType" : "variable",
              "element" : "code",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "CHE.B20S1.DE01"
                }
              ]
            }
          ]
        },
        {
          "name" : "aae7a11d",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "variable" : "itemtimestamp",
              "condition" : "linkId = 'timestamp'"
            }
          ],
          "rule" : [
            {
              "name" : "7f22f29f",
              "source" : [
                {
                  "context" : "itemtimestamp",
                  "element" : "answer",
                  "listMode" : "first",
                  "variable" : "atimestamp"
                }
              ],
              "rule" : [
                {
                  "name" : "5af77f2c",
                  "source" : [
                    {
                      "context" : "atimestamp",
                      "element" : "value",
                      "variable" : "val"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "issued",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "val"
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "patient",
          "source" : [
            {
              "context" : "src",
              "element" : "subject",
              "variable" : "subject"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "subject",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "subject"
                }
              ]
            }
          ]
        },
        {
          "name" : "fea7dc7e",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "listMode" : "first",
              "variable" : "item",
              "condition" : "(linkId = 'CHE.B20S1.DE01') and answer.exists()"
            }
          ],
          "rule" : [
            {
              "name" : "bdab9370",
              "source" : [
                {
                  "context" : "item",
                  "element" : "answer",
                  "listMode" : "first",
                  "variable" : "a"
                }
              ],
              "rule" : [
                {
                  "name" : "final-cheb20s1de01",
                  "source" : [
                    {
                      "context" : "a",
                      "condition" : "a.value = true"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "status",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "final"
                        }
                      ]
                    },
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "value",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueBoolean" : true
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "notfound-cheb20s1de01",
                  "source" : [
                    {
                      "context" : "a",
                      "condition" : "a.value = false"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "status",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "cancelled"
                        }
                      ]
                    },
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "value",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueBoolean" : false
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    },
    {
      "name" : "cheobservationcheb21s1de06",
      "typeMode" : "none",
      "input" : [
        {
          "name" : "src",
          "mode" : "source"
        },
        {
          "name" : "tgt",
          "mode" : "target"
        }
      ],
      "rule" : [
        {
          "name" : "id-cheb21s1de06",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "identifier",
              "variable" : "CodeID",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Identifier"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "system",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "http://hl7.org/fhir/namingsystem-identifier-type"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "use",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "official"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "value",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "uuid"
                }
              ]
            },
            {
              "context" : "CodeID",
              "contextType" : "variable",
              "element" : "id",
              "transform" : "uuid"
            }
          ]
        },
        {
          "name" : "35bc6b82",
          "source" : [
            {
              "context" : "src",
              "element" : "encounter",
              "variable" : "encounter"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "encounter",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "encounter"
                }
              ]
            }
          ]
        },
        {
          "name" : "code-cheb21s1de06",
          "source" : [
            {
              "context" : "src",
              "element" : "subject",
              "variable" : "subject"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "subject",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "subject"
                }
              ]
            },
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "meta",
              "variable" : "newMeta",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Meta"
                }
              ]
            },
            {
              "context" : "newMeta",
              "contextType" : "variable",
              "element" : "profile",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/StructureDefinition/cheobservation"
                }
              ]
            },
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "code",
              "variable" : "concept",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "CodeableConcept"
                }
              ]
            },
            {
              "context" : "concept",
              "contextType" : "variable",
              "element" : "coding",
              "variable" : "coding",
              "transform" : "create",
              "parameter" : [
                {
                  "valueString" : "Coding"
                }
              ]
            },
            {
              "context" : "coding",
              "contextType" : "variable",
              "element" : "system",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "https://fhir.dk.swisstph-mis.ch/matchbox/fhir/CodeSystem/che-custom-codes"
                }
              ]
            },
            {
              "context" : "coding",
              "contextType" : "variable",
              "element" : "code",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "CHE.B21S1.DE06"
                }
              ]
            }
          ]
        },
        {
          "name" : "aae7a11d",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "variable" : "itemtimestamp",
              "condition" : "linkId = 'timestamp'"
            }
          ],
          "rule" : [
            {
              "name" : "7f22f29f",
              "source" : [
                {
                  "context" : "itemtimestamp",
                  "element" : "answer",
                  "listMode" : "first",
                  "variable" : "atimestamp"
                }
              ],
              "rule" : [
                {
                  "name" : "5af77f2c",
                  "source" : [
                    {
                      "context" : "atimestamp",
                      "element" : "value",
                      "variable" : "val"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "issued",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "val"
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "patient",
          "source" : [
            {
              "context" : "src",
              "element" : "subject",
              "variable" : "subject"
            }
          ],
          "target" : [
            {
              "context" : "tgt",
              "contextType" : "variable",
              "element" : "subject",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "subject"
                }
              ]
            }
          ]
        },
        {
          "name" : "7b9a75da",
          "source" : [
            {
              "context" : "src",
              "element" : "item",
              "listMode" : "first",
              "variable" : "item",
              "condition" : "(linkId = 'CHE.B21S1.DE06') and answer.exists()"
            }
          ],
          "rule" : [
            {
              "name" : "bdab9370",
              "source" : [
                {
                  "context" : "item",
                  "element" : "answer",
                  "listMode" : "first",
                  "variable" : "a"
                }
              ],
              "rule" : [
                {
                  "name" : "final-cheb21s1de06",
                  "source" : [
                    {
                      "context" : "a",
                      "condition" : "a.value = true"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "status",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "final"
                        }
                      ]
                    },
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "value",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueBoolean" : true
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "notfound-cheb21s1de06",
                  "source" : [
                    {
                      "context" : "a",
                      "condition" : "a.value = false"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "status",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "cancelled"
                        }
                      ]
                    },
                    {
                      "context" : "tgt",
                      "contextType" : "variable",
                      "element" : "value",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueBoolean" : false
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    }
  ]
}