Skip to content

Commit

Permalink
Updated
Browse files Browse the repository at this point in the history
  • Loading branch information
rmrlangford committed Feb 5, 2024
1 parent 4f8cbdb commit 9097553
Showing 1 changed file with 8 additions and 27 deletions.
35 changes: 8 additions & 27 deletions input/maps/PropietaryEducationLevelToLOINCEducationLevel.fml
Original file line number Diff line number Diff line change
Expand Up @@ -7,31 +7,12 @@
uses "http://hl7.org/fhir/StructureDefinition/Observation" alias srcObservation as source
uses "http://hl7.org/fhir/StructureDefinition/Observation" alias tgtObservation as target

group SetPatientEducationalLevel(source obs : srcObservation, source coding: Coding, target observation : tgtObservation, target codeableConcept : CodeableConcept) {
/*obs.value -> observation.value = create('CodeableConcept') as value then {
obs.value -> value.coding = create('Coding') as coding then {
obs.value -> coding = translate(obs.value, 'http://openhie.org/fhir/zambia-immunizations/ConceptMap/ProprietaryEducationLevelToLOINCEducationLevel', 'code') "SetPatientEducation";
} "SetEducationalLevelCoding";
} "SetEducationalLevelCode";
obs.value -> observation.value = obs.value "SetPatientEducationalLevel";*/



//obs.value.first() as coding -> observation.value as educationLevel then {
// coding -> educationLevel.coding = translate(coding, 'http://openhie.org/fhir/zambia-immunizations/ConceptMap/ProprietaryEducationLevelToLOINCEducationLevel', 'code') "SetPatientEducation";
//} "SetEducationalLevelCode";

/*obs.value first as valueCodeableConcept then {
valueCodeableConcept -> observation.value as educationalLevel then {
valueCodeableConcept -> valueCodeableConcept then mapCodingtoCodeableConcept(valueCodeableConcept) "set code";
} "set code";
} "set";*/

/*obs.value : CodeableConcept as value,
value first as srcValueCodeableConcept,
observation.value : CodeableConcept as dstValueCodeableConcept then {
srcValueCodeableConcept -> dstValueCodeableConcept = translate(srcValueCodeableConcept, 'http://openhie.org/fhir/zambia-immunizations/ConceptMap/ProprietaryEducationLevelToLOINCEducationLevel', 'code') "SetPatientEducation";
} "TEST";*/


group SetPatientEducationalLevel(source obs : srcObservation, target observation : tgtObservation) {
obs.value : CodeableConcept as vs -> observation.value = create('CodeableConcept') as vt then MapCodeableConcept(vs, vt);
}

group MapCodeableConcept (source srcCodeableConcept: CodeableConcept, target tgtCodeableConcept : CodeableConcept) {
srcCodeableConcept.coding as coding then {
coding -> tgtCodeableConcept = translate(coding, 'http://openhie.org/fhir/zambia-immunizations/ConceptMap/ProprietaryEducationLevelToLOINCEducationLevel', 'code') "SetPatientEducationCode";
} "SetPatientEducationCoding";
}

0 comments on commit 9097553

Please sign in to comment.