This page is part of the FHIR Core Extensions Registry (v5.1.0: Release 5.1) based on FHIR (HL7® FHIR® Standard) v5.0.0. This is the current published version. For a full list of available versions, see the Directory of published versions
Page standards status: Trial-use | Maturity Level: 1 |
{
"resourceType" : "StructureMap",
"id" : "EpisodeOfCare4Bto5",
"text" : {
"status" : "generated",
"div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><pre class=\"fml\">\r\n<span style=\"color: #cc00cc\">/// <b>url</b> = </span><span style=\"color: blue\">'http://hl7.org/fhir/StructureMap/EpisodeOfCare4Bto5'</span>\r\n<span style=\"color: #cc00cc\">/// <b>name</b> = </span><span style=\"color: blue\">'EpisodeOfCare4Bto5'</span>\r\n<span style=\"color: #cc00cc\">/// <b>title</b> = </span><span style=\"color: blue\">'FML Conversion for EpisodeOfCare: R4B to R5'</span>\r\n<span style=\"color: #cc00cc\">/// <b>status</b> = </span><span style=\"color: blue\">'active'</span>\r\n\r\n<b>conceptmap</b><span style=\"color: navy\"> "</span>EpisodeOfCareStatus<span style=\"color: navy\">" {\r\n</span><b> prefix </b>s<span style=\"color: navy\"> = "</span><a href=\"http://hl7.org/fhir/R4B/codesystem-episode-of-care-status.html\" title=\"EpisodeOfCareStatus\">http://hl7.org/fhir/4.3/episode-of-care-status</a><span style=\"color: navy\">"\r\n</span><b> prefix </b>t<span style=\"color: navy\"> = "</span><a href=\"http://hl7.org/fhir/R5/codesystem-episode-of-care-status.html\" title=\"Episode Of Care Status\">http://hl7.org/fhir/episode-of-care-status</a><span style=\"color: navy\">"\r\n</span>\r\n s<span style=\"color: navy\">:</span>planned <b>-</b> t<span style=\"color: navy\">:</span>planned\r\n s<span style=\"color: navy\">:</span>waitlist <b>-</b> t<span style=\"color: navy\">:</span>waitlist\r\n s<span style=\"color: navy\">:</span>active <b>-</b> t<span style=\"color: navy\">:</span>active\r\n s<span style=\"color: navy\">:</span>onhold <b>-</b> t<span style=\"color: navy\">:</span>onhold\r\n s<span style=\"color: navy\">:</span>finished <b>-</b> t<span style=\"color: navy\">:</span>finished\r\n s<span style=\"color: navy\">:</span>cancelled <b>-</b> t<span style=\"color: navy\">:</span>cancelled\r\n s<span style=\"color: navy\">:</span>"entered-in-error" <b>-</b> t<span style=\"color: navy\">:</span><span style=\"color: navy\">"</span>entered-in-error<span style=\"color: navy\">"</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span><b>uses</b><span style=\"color: navy\"> "</span><a href=\"http://hl7.org/fhir/R4B/episodeofcare.html\" title=\"EpisodeOfCare\">http://hl7.org/fhir/4.3/StructureDefinition/EpisodeOfCare</a><span style=\"color: navy\">" </span><b>alias </b>EpisodeOfCareR4B <b>as </b><b>source</b>\r\n<b>uses</b><span style=\"color: navy\"> "</span><a href=\"http://hl7.org/fhir/R5/episodeofcare.html\" title=\"EpisodeOfCare\">http://hl7.org/fhir/StructureDefinition/EpisodeOfCare</a><span style=\"color: navy\">" </span><b>alias </b>EpisodeOfCareR5 <b>as </b><b>target</b>\r\n\r\n<b>imports</b><span style=\"color: navy\"> "</span>http://hl7.org/fhir/StructureMap/*4Bto5<span style=\"color: navy\">"\r\n</span>\r\n<b>group </b>EpisodeOfCare<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span><span style=\"color: navy\"> : </span>EpisodeOfCareR4B, <b>target</b> <span style=\"color: maroon\">tgt</span><span style=\"color: navy\"> : </span>EpisodeOfCareR5<span style=\"color: navy\">)</span><b> extends </b>DomainResource<b> <<type+>></b><span style=\"color: navy\"> {\r\n</span> src.identifier<span style=\"color: navy\"><b> -> </b></span>tgt.identifier<span style=\"color: navy\">;</span>\r\n src.status<b> as </b><span style=\"color: maroon\">v</span><span style=\"color: navy\"><b> -> </b></span>tgt.status = <b>translate</b><span style=\"color: navy\">(</span><span style=\"color: maroon\">v</span><span style=\"color: navy\">, </span><span style=\"color: blue\">'#EpisodeOfCareStatus'</span><span style=\"color: navy\">, </span><span style=\"color: blue\">'code'</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>\r\n src.statusHistory<b> as </b><span style=\"color: maroon\">s</span><span style=\"color: navy\"><b> -> </b></span>tgt.statusHistory<b> as </b><span style=\"color: maroon\">t</span><b> then </b>EpisodeOfCareStatusHistory<span style=\"color: navy\">(</span><span style=\"color: maroon\">s</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">t</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>\r\n src.type<span style=\"color: navy\"><b> -> </b></span>tgt.type<span style=\"color: navy\">;</span>\r\n src.diagnosis<b> as </b><span style=\"color: maroon\">s</span><span style=\"color: navy\"><b> -> </b></span>tgt.diagnosis<b> as </b><span style=\"color: maroon\">t</span><b> then </b>EpisodeOfCareDiagnosis<span style=\"color: navy\">(</span><span style=\"color: maroon\">s</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">t</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span> <span style=\"color: navy\">// </span><span style=\"color: green\">src.reason as s -> tgt.reason as t then EpisodeOfCareReason(s,t);</span>\r\n src.patient<span style=\"color: navy\"><b> -> </b></span>tgt.patient<span style=\"color: navy\">;</span>\r\n src.managingOrganization<span style=\"color: navy\"><b> -> </b></span>tgt.managingOrganization<span style=\"color: navy\">;</span>\r\n src.period<span style=\"color: navy\"><b> -> </b></span>tgt.period<span style=\"color: navy\">;</span>\r\n src.referralRequest<span style=\"color: navy\"><b> -> </b></span>tgt.referralRequest<span style=\"color: navy\">;</span>\r\n src.careManager<span style=\"color: navy\"><b> -> </b></span>tgt.careManager<span style=\"color: navy\">;</span>\r\n src.team<span style=\"color: navy\"><b> -> </b></span>tgt.careTeam<span style=\"color: navy\">;</span>\r\n src.account<span style=\"color: navy\"><b> -> </b></span>tgt.account<span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span><b>group </b>EpisodeOfCareStatusHistory<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span>, <b>target</b> <span style=\"color: maroon\">tgt</span><span style=\"color: navy\">)</span><b> extends </b>BackboneElement<span style=\"color: navy\"> {\r\n</span> src.status<b> as </b><span style=\"color: maroon\">v</span><span style=\"color: navy\"><b> -> </b></span>tgt.status = <b>translate</b><span style=\"color: navy\">(</span><span style=\"color: maroon\">v</span><span style=\"color: navy\">, </span><span style=\"color: blue\">'#EpisodeOfCareStatus'</span><span style=\"color: navy\">, </span><span style=\"color: blue\">'code'</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>\r\n src.period<span style=\"color: navy\"><b> -> </b></span>tgt.period<span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span><span style=\"color: navy\">// </span><span style=\"color: green\">group EpisodeOfCareReason(source src, target tgt) extends BackboneElement {</span>\r\n<span style=\"color: #b36b00\" title=\"This element was not defined prior to R5\">// src.use -> tgt.use;</span>\r\n<span style=\"color: #b36b00\" title=\"This element was not defined prior to R5\">// src.value -> tgt.value;</span>\r\n<span style=\"color: navy\">// </span><span style=\"color: green\">}</span>\r\n<b>group </b>EpisodeOfCareDiagnosis<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span>, <b>target</b> <span style=\"color: maroon\">tgt</span><span style=\"color: navy\">)</span><b> extends </b>BackboneElement<span style=\"color: navy\"> {\r\n</span> src.condition<span style=\"color: navy\"><b> -> </b></span>tgt.condition<span style=\"color: navy\">;</span>\r\n src.role<span style=\"color: navy\"><b> -> </b></span>tgt.use<span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span></pre></div>"
},
"contained" : [
{
"resourceType" : "ConceptMap",
"id" : "EpisodeOfCareStatus",
"status" : "active",
"group" : [
{
"source" : "http://hl7.org/fhir/4.3/episode-of-care-status",
"target" : "http://hl7.org/fhir/episode-of-care-status",
"element" : [
{
"code" : "planned",
"target" : [
{
"code" : "planned",
"relationship" : "related-to"
}
]
},
{
"code" : "waitlist",
"target" : [
{
"code" : "waitlist",
"relationship" : "related-to"
}
]
},
{
"code" : "active",
"target" : [
{
"code" : "active",
"relationship" : "related-to"
}
]
},
{
"code" : "onhold",
"target" : [
{
"code" : "onhold",
"relationship" : "related-to"
}
]
},
{
"code" : "finished",
"target" : [
{
"code" : "finished",
"relationship" : "related-to"
}
]
},
{
"code" : "cancelled",
"target" : [
{
"code" : "cancelled",
"relationship" : "related-to"
}
]
},
{
"code" : "entered-in-error",
"target" : [
{
"code" : "entered-in-error",
"relationship" : "related-to"
}
]
}
]
}
]
}
],
"extension" : [
{
"url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
"valueCode" : "fhir"
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm",
"valueInteger" : 1,
"_valueInteger" : {
"extension" : [
{
"url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-conformance-derivedFrom",
"valueCanonical" : "http://hl7.org/fhir/extensions/ImplementationGuide/hl7.fhir.uv.extensions"
}
]
}
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
"valueCode" : "trial-use",
"_valueCode" : {
"extension" : [
{
"url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-conformance-derivedFrom",
"valueCanonical" : "http://hl7.org/fhir/extensions/ImplementationGuide/hl7.fhir.uv.extensions"
}
]
}
}
],
"url" : "http://hl7.org/fhir/StructureMap/EpisodeOfCare4Bto5",
"version" : "5.1.0",
"name" : "EpisodeOfCare4Bto5",
"title" : "FML Conversion for EpisodeOfCare: R4B to R5",
"status" : "active",
"date" : "2024-04-27T18:54:50+10:00",
"publisher" : "HL7 International / FHIR Infrastructure",
"contact" : [
{
"telecom" : [
{
"system" : "url",
"value" : "http://www.hl7.org/Special/committees/fiwg"
}
]
}
],
"description" : "FMLConversionforEpisodeOfCareR4BtoR5",
"jurisdiction" : [
{
"coding" : [
{
"system" : "http://unstats.un.org/unsd/methods/m49/m49.htm",
"code" : "001"
}
]
}
],
"structure" : [
{
"url" : "http://hl7.org/fhir/4.3/StructureDefinition/EpisodeOfCare",
"mode" : "source",
"alias" : "EpisodeOfCareR4B"
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/EpisodeOfCare",
"mode" : "target",
"alias" : "EpisodeOfCareR5"
}
],
"import" : [
"http://hl7.org/fhir/StructureMap/*4Bto5"
],
"group" : [
{
"name" : "EpisodeOfCare",
"extends" : "DomainResource",
"typeMode" : "type-and-types",
"input" : [
{
"name" : "src",
"type" : "EpisodeOfCareR4B",
"mode" : "source"
},
{
"name" : "tgt",
"type" : "EpisodeOfCareR5",
"mode" : "target"
}
],
"rule" : [
{
"name" : "identifier",
"source" : [
{
"context" : "src",
"element" : "identifier",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "identifier",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "status",
"source" : [
{
"context" : "src",
"element" : "status",
"variable" : "v"
}
],
"target" : [
{
"context" : "tgt",
"element" : "status",
"transform" : "translate",
"parameter" : [
{
"valueId" : "v"
},
{
"valueString" : "#EpisodeOfCareStatus"
},
{
"valueString" : "code"
}
]
}
]
},
{
"name" : "statusHistory",
"source" : [
{
"context" : "src",
"element" : "statusHistory",
"variable" : "s"
}
],
"target" : [
{
"context" : "tgt",
"element" : "statusHistory",
"variable" : "t"
}
],
"dependent" : [
{
"name" : "EpisodeOfCareStatusHistory",
"parameter" : [
{
"valueId" : "s"
},
{
"valueId" : "t"
}
]
}
]
},
{
"name" : "type",
"source" : [
{
"context" : "src",
"element" : "type",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "type",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "diagnosis",
"source" : [
{
"context" : "src",
"element" : "diagnosis",
"variable" : "s"
}
],
"target" : [
{
"context" : "tgt",
"element" : "diagnosis",
"variable" : "t"
}
],
"dependent" : [
{
"name" : "EpisodeOfCareDiagnosis",
"parameter" : [
{
"valueId" : "s"
},
{
"valueId" : "t"
}
]
}
],
"documentation" : "src.reason as s -> tgt.reason as t then EpisodeOfCareReason(s,t);"
},
{
"name" : "patient",
"source" : [
{
"context" : "src",
"element" : "patient",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "patient",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "managingOrganization",
"source" : [
{
"context" : "src",
"element" : "managingOrganization",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "managingOrganization",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "period",
"source" : [
{
"context" : "src",
"element" : "period",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "period",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "referralRequest",
"source" : [
{
"context" : "src",
"element" : "referralRequest",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "referralRequest",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "careManager",
"source" : [
{
"context" : "src",
"element" : "careManager",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "careManager",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "team",
"source" : [
{
"context" : "src",
"element" : "team",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "careTeam",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "account",
"source" : [
{
"context" : "src",
"element" : "account",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "account",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
}
]
},
{
"name" : "EpisodeOfCareStatusHistory",
"extends" : "BackboneElement",
"input" : [
{
"name" : "src",
"mode" : "source"
},
{
"name" : "tgt",
"mode" : "target"
}
],
"rule" : [
{
"name" : "status",
"source" : [
{
"context" : "src",
"element" : "status",
"variable" : "v"
}
],
"target" : [
{
"context" : "tgt",
"element" : "status",
"transform" : "translate",
"parameter" : [
{
"valueId" : "v"
},
{
"valueString" : "#EpisodeOfCareStatus"
},
{
"valueString" : "code"
}
]
}
]
},
{
"name" : "period",
"source" : [
{
"context" : "src",
"element" : "period",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "period",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
}
]
},
{
"name" : "EpisodeOfCareDiagnosis",
"extends" : "BackboneElement",
"documentation" : "group EpisodeOfCareReason(source src, target tgt) extends BackboneElement {\r\nsrc.use -> tgt.use;\r\nsrc.value -> tgt.value;\r\n}",
"input" : [
{
"name" : "src",
"mode" : "source"
},
{
"name" : "tgt",
"mode" : "target"
}
],
"rule" : [
{
"name" : "condition",
"source" : [
{
"context" : "src",
"element" : "condition",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "condition",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "role",
"source" : [
{
"context" : "src",
"element" : "role",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "use",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
}
]
}
]
}