num-codex / odm2fhir

This tool maps study/patient data in CDISC ODM based on the GECCO data dictionary to HL7 FHIR which adheres to the GECCO profiles, value sets and code systems.
MIT License
4 stars 1 forks source link

Patient id missing #9

Closed noemide closed 3 years ago

noemide commented 3 years ago

Describe the bug With 0.1.3-alpha-SNAPSHOT, the generated Patient resource does not have an id, making all references to it meaningless.

Entry is

{
    "fullUrl": "urn:uuid:14226339-440d-44c0-802c-ac5453792625",
    "resource": {
      "resourceType": "Patient",
      "meta": {
        "profile": [ "https://www.netzwerk-universitaetsmedizin.de/fhir/StructureDefinition/Patient" ]
      }
    },
    "request": {
      "method": "POST",
      "url": "Patient"
    }
  },

Observation is

{
    "fullUrl": "urn:uuid:95511879-9bcd-4d5a-975c-32fcf146b0aa",
    "resource": {
      "resourceType": "Observation",
      "meta": {
        "profile": [ "https://www.netzwerk-universitaetsmedizin.de/fhir/StructureDefinition/body-weight" ]
      },
      "status": "final",
      "category": [ {
        "coding": [ {
          "system": "http://terminology.hl7.org/CodeSystem/observation-category",
          "code": "vital-signs",
          "display": "Vital Signs"
        } ]
      } ],
      "code": {
        "coding": [ {
          "system": "http://loinc.org",
          "code": "29463-7"
        }, {
          "system": "http://snomed.info/sct",
          "code": "27113001"
        } ],
        "text": "Body Weight"
      },
      "subject": {
        "identifier": {
          "value": "Patient/123456789"
        }
      },
      "valueQuantity": {
        "value": 123,
        "unit": "kilogram",
        "system": "http://unitsofmeasure.org",
        "code": "kg"
      }
    },
    "request": {
      "method": "POST",
      "url": "Observation"
    }
  }

To Reproduce Steps to reproduce the behavior:

  1. Create new record in Recap
  2. Enter Patient Id
  3. Enter other information (e.g. "Körpergewicht")
  4. Run ODM2FHIR
  5. Resulting bundle has no patient id

Expected behavior Bundle with Patient resource and Observation referencing Patient via id

Screenshots grafik grafik

Desktop (please complete the following information):

Found by @joundso

holger-stenzhorn commented 3 years ago

Fixed in latest snapshot...