hl7ch / cda-fhir-maps

Maps (FHIR Mapping Language) to transform documents from CDA to FHIR and back
Apache License 2.0
19 stars 8 forks source link

FHIR to CDA conversion problems Medication Treatment Plan #21

Closed oliveregger closed 3 years ago

oliveregger commented 3 years ago

Validation is not converting correctly:

https://ehealthsuisse.ihe-europe.net/EVSClient//detailedResult.seam?type=FHIR&oid=1.3.6.1.4.1.12559.11.25.1.13.47855

https://ehealthsuisse.ihe-europe.net/EVSClient//detailedResult.seam?type=CDA&oid=1.3.6.1.4.1.12559.11.25.1.13.47845

qligier commented 3 years ago

Every value that goes into a CDA ID attribute should be checked. For this file,

{
 "resource":{
   "resourceType":"Binary",
   "id":"1",
   ...
  }
}

gives the invalid

<observationMedia ID="1" ... />

CDA IDs must follow the xs:NCName restrictions:

    NCName ::= (Letter | '_') (NCNameChar)*
NCNameChar ::= Letter | Digit | '.' | '-' | '_' | CombiningChar | Extender
oliveregger commented 3 years ago

patientRole.id missing -> Patient.identifier system is http based, this is not working with CDA, we need an oid system identifier.

oliveregger commented 3 years ago

missing id on the representedCustodianOrganization -> Organization.identifier system is http based, this is not working with CDA, we need an oid system identifier.

oliveregger commented 3 years ago

timingevents occured multiple times, because sequence numbers were not provided for dosage.

https://github.com/ehealthsuisse/ch-emed/issues/58

oliveregger commented 3 years ago

CDA Validation: https://ehealthsuisse.ihe-europe.net/EVSClient//detailedResult.seam?type=CDA&oid=1.3.6.1.4.1.12559.11.25.1.13.48407

CH-EMED Validation https://ehealthsuisse.ihe-europe.net/EVSClient//detailedResult.seam?type=FHIR&oid=1.3.6.1.4.1.12559.11.25.1.13.48408 (error due to truncated pdf)