R4 Ballot #1 (Mixed Normative/Trial use)

This page is part of the FHIR Specification (v3.3.0: R4 Ballot 2). The current version which supercedes this version is 5.0.0. For a full list of available versions, see the Directory of published versions . Page versions: R5 R4B R4 R3

Orders and Observations Work GroupMaturity Level: N/ABallot Status: Informative Compartments: Device, Encounter, Patient, Practitioner

R2 : R3 Conversion maps for DeviceRequest.

Functional status for this map: Not Mapped (see documentation)

map "http://hl7.org/fhir/StructureMap/DeviceUseRequest2to3" = "R2 to R3 Conversions for DeviceUseRequest"

conceptmap "RequestStatus" {
  prefix s = "http://hl7.org/fhir/device-use-request-status"
  prefix t = "http://hl7.org/fhir/request-status"

  s:proposed = t:draft
  s:planned = t:draft
  s:requested = t:active
  s:received = t:active
  s:accepted = t:active
  s:"in-progress" = t:active
  s:completed = t:completed
  s:suspended = t:suspended
  s:rejected = t:cancelled
  s:aborted = t:cancelled
}

uses "http://hl7.org/fhir/DSTU2/StructureDefinition/DeviceUseRequest" alias DeviceUseRequestR2 as source
uses "http://hl7.org/fhir/StructureDefinition/DeviceRequest" alias DeviceRequest as target

imports "http://hl7.org/fhir/StructureMap/*2to3"

group for type+types  DeviceUseRequest extends DomainResource
  input src : DeviceUseRequestR2 as source
  input tgt : DeviceRequest as target

  // drop bodySite
  "DeviceUseRequest-status" : for src.status as v make tgt.status = translate(v, "#RequestStatus", "code")
  "DeviceUseRequest-device" : for src.device make tgt.device
  "DeviceUseRequest-context" : for src.encounter make tgt.context
  "DeviceUseRequest-identifier" : for src.identifier make tgt.identifier
  "DeviceUseRequest-reasonCode" : for src.indication make tgt.reasonCode
  "DeviceUseRequest-notes" : for src.notes make tgt.note
  // drop prnReason
  "DeviceUseRequest-authored" : for src.orderedOn make tgt.authored
  "DeviceUseRequest-subject" : for src.subject make tgt.subject
  "DeviceUseRequest-Timing" : for src.timing make tgt.occurrence
  // drop priority

endgroup

map "http://hl7.org/fhir/StructureMap/DeviceUseRequest3to2" = "R3 to R2 Conversion for DeviceUseRequest"

conceptmap "RequestStatus" {
  prefix s = "http://hl7.org/fhir/device-use-request-status"
  prefix t = "http://hl7.org/fhir/request-status"

  s:draft = t:proposed
  s:active = t:"in-progress"
  s:suspended = t:suspended
  s:completed = t:completed
  s:cancelled = t:rejected
}

uses "http://hl7.org/fhir/StructureDefinition/DeviceRequest" alias DeviceRequest as source
uses "http://hl7.org/fhir/DSTU2/StructureDefinition/DeviceUseRequest" alias DeviceUseRequestR2 as target

imports "http://hl7.org/fhir/StructureMap/*3to2"

group for type+types  DeviceRequest extends DomainResource
  input src : DeviceRequest as source
  input tgt : DeviceUseRequestR2 as target

  "DeviceRequest-status" : for src.status as v check src.status != 'entered-in-error' make tgt.status = translate(v, "#RequestStatus", "code")
  "DeviceRequest-device" : for src.device make tgt.device
  "DeviceRequest-context" : for src.context make tgt.encounter
  "DeviceRequest-identifier" : for src.identifier make tgt.identifier
  "DeviceRequest-reasonCode" : for src.reasonCode make tgt.indication
  "DeviceRequest-notes" : for src.note make tgt.notes
  "DeviceRequest-authored" : for src.authored make tgt.orderedOn
  "DeviceRequest-subject" : for src.subject make tgt.subject
  "DeviceRequest-Timing" : for src.occurrence make tgt.timing
endgroup

n/a