Skip to content

Commit

Permalink
Merge pull request #2 from jembi/smartcare-initial
Browse files Browse the repository at this point in the history
Smartcare initial
  • Loading branch information
rmrlangford authored Feb 1, 2024
2 parents 81e6335 + 526ef74 commit 19ff396
Show file tree
Hide file tree
Showing 5 changed files with 594 additions and 40 deletions.
8 changes: 4 additions & 4 deletions input/fsh/conceptmaps/client-registration.fsh
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ Usage: #definition
* source = $PROPRIETARY_EDU_LEVEL
* target = $LNC
* insert ElementMap(CertificateGraduate, LA30193-9, equivalent)
* insert ElementMap(DegreeGraduate, LA42-7, equivalent)
* insert ElementMap(DiplomaGraduate, LA32469-1, equivalent)
* insert ElementMap(DegreeGraduate, LA32469-1, equivalent)
* insert ElementMap(DiplomaGraduate, LA12459-6, equivalent)
* insert ElementMap(JuniorSecondary, LA36-9, equivalent)
* insert ElementMap(MastersGraduate, LA12461-2, equivalent)
* insert ElementMap(NoFormalEducation, LA35-1, equivalent)
Expand All @@ -53,8 +53,8 @@ Usage: #definition
* source = $LNC
* target = $PROPRIETARY_EDU_LEVEL
* insert ElementMap(LA30193-9, CertificateGraduate, equivalent)
* insert ElementMap(LA42-7, DegreeGraduate, equivalent)
* insert ElementMap(LA32469-1, DiplomaGraduate, equivalent)
* insert ElementMap(LA32469-1, DegreeGraduate, equivalent)
* insert ElementMap(LA12459-6, DiplomaGraduate, equivalent)
* insert ElementMap(LA36-9, JuniorSecondary, equivalent)
* insert ElementMap(LA12461-2, MastersGraduate, equivalent)
* insert ElementMap(LA35-1, NoFormalEducation, equivalent)
Expand Down
230 changes: 217 additions & 13 deletions input/fsh/examples.fsh
Original file line number Diff line number Diff line change
@@ -1,20 +1,224 @@
Instance: HImmunizationPatientExample
Instance: ImmunizationPatientExample
InstanceOf: ImmunizationPatient
Usage: #example
Title: "Immunization Patient"
Description: "Is used to document demographics and other administrative information about an individual receiving care or other health-related services."
* identifier[NUPIN][+].value = "12-999-22-2338"
* identifier[NUPIN][=].system = "http://openhie.org/fhir/zambia-immunizations/identifier/nupin"
* identifier[NRC][+].value = "12-999-22-2338"
* identifier[NRC][=].system = "http://openhie.org/fhir/zambia-immunizations/identifier/nrc"
* name[+].use = #official
* name[=].family = "Smith"
* name[=].given[+] = "Jane"
* name[=].given[+] = "Maria"
* identifier[NUPIN][+].value = "1001-XXGB0-12345-5"
* identifier[NUPIN][=].system = "http://openhie.org/fhir/zambia-immunizations/identifier/patient-nupin"
* identifier[NRC][+].value = "999999/99/9"
* identifier[NRC][=].system = "http://openhie.org/fhir/zambia-immunizations/identifier/patient-nrc"
* name[+][official].use = #official
* name[=][official].family = "Smith"
* name[=][official].given[+] = "Jane"
* name[=][official].given[+] = "Maria"
* gender = #female
* birthDate = "1990-12-12"
* birthDate.extension[birthTime].valueDateTime = "1983-05-22T16:40:17+02:00"
* extension[BIZ].valueBoolean = true
* extension[IsEstimatedDOB].valueBoolean = false
* extension[EducationLevelAttained].valueCodeableConcept.coding.code = $LNC#LA42-7
* extension[EducationLevelAttained].valueCodeableConcept.coding.system = "http://loinc.org"
* birthDate.extension[IsEstimatedDOB].valueBoolean = false
* maritalStatus.coding.code = #M
* maritalStatus.coding.system = "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus"
//* maritalStatus.extension[DateFirstMarried].valueDateTime = "2001-11-10T12:05:17+02:00"
* extension[bornInZambia].valueBoolean = true
* link[+].other = Reference(SpouseRelatedPersonExample)
* link[=].type = #seealso
* extension[religion].valueCodeableConcept.coding.code = #1013
* extension[religion].valueCodeableConcept.coding.system = "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation"
* extension[religion].valueCodeableConcept.text = "Christian (non-Catholic, non-specific)"
* managingOrganization = Reference(OrganizationExample)

Instance: SpouseRelatedPersonExample
InstanceOf: SpouseRelatedPerson
Usage: #example
Title: "Spouse Related to Patient"
Description: "The husband or wife, considered in relation to the patient."
* patient = Reference(ImmunizationPatientExample)
* name[+].use = #official
* name[=].family = "Jones"
* name[=].given[+] = "Mike"
* telecom[+][phone].system = #phone
* telecom[=][phone].value = "+27821234567"
* relationship = $SCT#127850001

Instance: PatientEducationalLevelObservationExample
InstanceOf: PatientEducationalLevelObservation
Usage: #example
Title: "Highest education level attained"
Description: "A patient's highest education level attained"
* status = #final
* code = $LNC#LL5338-0
* encounter = Reference(TargetFacilityEncounterExample)
* effectiveDateTime = "2022-11-30"
* valueCodeableConcept = $LNC#LA42-7
* valueCodeableConcept.text = "Graduate degree"
* category.coding.code = #social-history
* category.coding.system = "http://terminology.hl7.org/CodeSystem/observation-category"
* subject = Reference (ImmunizationPatientExample)
* performer = Reference(OrganizationExample)

Instance: TargetFacilityEncounterExample
InstanceOf: TargetFacilityEncounter
Usage: #example
Title: "Target Facility Encounter"
Description: "Represents the current facility at which the patient is receiving health services."
* status = #completed
* class.coding.code = #AMB
* class.coding.system = "http://terminology.hl7.org/CodeSystem/v3-ActCode"
* subject = Reference(ImmunizationPatientExample)
* actualPeriod.start = "2022-12-01"
* actualPeriod.end = "2023-01-20"

Instance: OrganizationExample
InstanceOf: ServiceProvider
Usage: #example
Title: "Organization"
Description: "Organization providing health related services."
* identifier[XX].value = "facility-1"
* identifier[XX].system = "http://openhie.org/fhir/zambia-immunizations/identifier/organization"
* identifier[XX].type.coding.code = #XX
* identifier[XX].type.coding.system = "http://terminology.hl7.org/CodeSystem/v2-0203"
* identifier[XX].type.text = "Organization identifier"
* name = "Facility one"

Instance: ChiefAtBirthRelatedPersonExample
InstanceOf: ChiefAtBirthRelatedPerson
Usage: #example
Title: "Chief at Birth"
Description: "Patient'a chief at birth."
* patient = Reference(ImmunizationPatientExample)
* name[+].use = #official
* name[=].family = "Jones"
* relationship = $SCT#303119007

Instance: DatePatientFirstMarriedObservationExample
InstanceOf: DatePatientFirstMarriedObservation
Usage: #example
Title: "Patient's Date of First Marriage"
Description: "Records the date when the patient was first married"
* status = #final
* code = $SCT#365581002
* encounter = Reference(TargetFacilityEncounterExample)
* effectiveDateTime = "2022-11-30"
* valueDateTime = "1983-05-22T16:40:17+02:00"
* category.coding.code = #social-history
* category.coding.system = "http://terminology.hl7.org/CodeSystem/observation-category"
* subject = Reference (ImmunizationPatientExample)
* performer = Reference(OrganizationExample)

Instance: PatientFatherRelatedPersonExample
InstanceOf: PatientFatherRelatedPerson
Usage: #example
Title: "Father Relation to Patient"
Description: "The patient's father."
* patient = Reference(ImmunizationPatientExample)
* name[+].use = #official
* name[=].given[+] = "Mike"
* relationship = $PARENT_RELATIONSHIP_CODES#FTH

Instance: GenericObservationExample
InstanceOf: GenericObservation
Usage: #example
Title: "Generic Social History Observation Profile"
Description: "This profile acts as a base profile from which more specific social history observation profiles can be derived."
* status = #final
* code = $SCT#160476009
* encounter = Reference(TargetFacilityEncounterExample)
* effectiveDateTime = "2022-11-30"
* category.coding.code = #social-history
* category.coding.system = "http://terminology.hl7.org/CodeSystem/observation-category"
* subject = Reference (ImmunizationPatientExample)
* performer = Reference(OrganizationExample)

Instance: GuardianOccupationObservationExample
InstanceOf: GuardianOccupationObservation
Usage: #example
Title: "Guardian Occupation"
Description: "Records the current occupation for the guardian"
* status = #final
* code = $LNC#11341-5
* encounter = Reference(TargetFacilityEncounterExample)
* effectiveDateTime = "2022-11-30"
* category.coding.code = #social-history
* category.coding.system = "http://terminology.hl7.org/CodeSystem/observation-category"
* subject = Reference (ImmunizationPatientExample)
* performer = Reference(OrganizationExample)
* valueCodeableConcept = $SCT#79859009
* valueCodeableConcept.text = "Computer programmer"

Instance: GuardianRelatedPersonExample
InstanceOf: GuardianRelatedPerson
Usage: #example
Title: "Guardian Relation to Patient"
Description: "A guardian to the patient."
* patient = Reference(ImmunizationPatientExample)
* name[+].use = #official
* name[=].given[+] = "Mike"
* name[=].family = "Smith"
* relationship = $SCT#394619001

Instance: PatientMotherRelatedPersonExample
InstanceOf: PatientMotherRelatedPerson
Usage: #example
Title: "Mother Relation to Patient"
Description: "The patient's mother."
* patient = Reference(ImmunizationPatientExample)
* name[+].use = #official
* name[=].given[+] = "Olivia"
* name[=].family = "Smith"
* relationship = $PARENT_RELATIONSHIP_CODES#MTH

Instance: RelationToPatientExample
InstanceOf: RelationToPatient
Usage: #example
Title: "Generic Relation to Patient"
Description: "This profile acts as a base profile from which more specific RelatedPerson profiles can be derived."
* identifier[NRC][+].value = "999999/99/9"
* identifier[NRC][=].system = "http://openhie.org/fhir/zambia-immunizations/identifier/relative-nrc"
* patient = Reference(ImmunizationPatientExample)
* name[+].use = #official
* name[=].given[+] = "Olivia"
* name[=].family = "Smith"
* relationship = $PARENT_RELATIONSHIP_CODES#MTH

Instance: RelativeRelatedPersonExample
InstanceOf: RelativeRelatedPerson
Usage: #example
Title: "Relative Relation to Patient"
Description: "The patient's relative."
* patient = Reference(ImmunizationPatientExample)
* name[+].use = #official
* name[=].given[+] = "Olivia"
* name[=].family = "Smith"
* relationship = $SCT#125677006

Instance: SpouseOccupationObservationExample
InstanceOf: SpouseOccupationObservation
Usage: #example
Title: "Spouse Occupation"
Description: "Records the current occupation for the spouse"
* status = #final
* code = $SCT#447057006
* encounter = Reference(TargetFacilityEncounterExample)
* effectivePeriod.start = "2017-03-01"
* category.coding.code = #social-history
* category.coding.system = "http://terminology.hl7.org/CodeSystem/observation-category"
* subject = Reference (ImmunizationPatientExample)
* performer = Reference(OrganizationExample)
* valueCodeableConcept = $SCT#11205001
* valueCodeableConcept.text = "Judge"

Instance: PatientHomeLanguageObservationExample
InstanceOf: PatientHomeLanguageObservation
Usage: #example
Title: "Patient's Home Language"
Description: "Records the home language for the patient"
* status = #final
* code = $SCT#224076006
* encounter = Reference(TargetFacilityEncounterExample)
* effectiveDateTime = "2022-11-30"
* category.coding.code = #social-history
* category.coding.system = "http://terminology.hl7.org/CodeSystem/observation-category"
* subject = Reference (ImmunizationPatientExample)
* performer = Reference(OrganizationExample)
* valueCodeableConcept.coding.code = #Chokwe
* valueCodeableConcept.coding.system = "http://openhie.org/fhir/zambia-immunizations/CodeSystem/cs-home-language"
* valueCodeableConcept.text = "Chokwe"
15 changes: 12 additions & 3 deletions input/fsh/extensions.fsh
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ Description: "This is an extension to capture whether the patient's date of birt
* value[x] only boolean
* value[x] 1..
* ^context[+].type = #element
* ^context[=].expression = "Patient"
* ^context[=].expression = "Patient.birthDate"

Extension: EducationLevelAttained
/*Extension: EducationLevelAttained
Id: education-level-attained
Title: "Patient's highest education level attained"
Description: "A list of education levels."
Expand All @@ -26,4 +26,13 @@ Description: "A list of education levels."
* valueCodeableConcept.coding.system 1..1
* valueCodeableConcept.coding.code 1..1
* ^context[0].type = #element
* ^context[0].expression = "Patient"
* ^context[0].expression = "Patient"*/

/*Extension: DateOfFirstMarriage
Id: date-of-first-marriage
Title: "Patient's Date of First Marriage"
Description: "This is an extension to capture the date when the patient first got married."
* value[x] only dateTime
* value[x] 1..
* ^context[+].type = #element
* ^context[=].expression = "Patient.maritalStatus"*/
Loading

0 comments on commit 19ff396

Please sign in to comment.