Skip to content

Commit

Permalink
fix build errors, update load script
Browse files Browse the repository at this point in the history
  • Loading branch information
citizenrich committed Jul 10, 2023
1 parent f3b4c26 commit f94dc0b
Show file tree
Hide file tree
Showing 5 changed files with 63 additions and 29 deletions.
6 changes: 6 additions & 0 deletions input/cql/Debug.cql
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@ parameter "Measurement Period" Interval<DateTime> default Interval[@1990-01-01T,
context Patient



define "Exists Patient":
exists ["Patient"] P



define "Deceased":
Patient.deceased is not null
and (Patient.deceased is true or Patient.deceased before end of "Measurement Period")
Expand Down
52 changes: 37 additions & 15 deletions input/fsh/measure.fsh
Original file line number Diff line number Diff line change
Expand Up @@ -93,19 +93,41 @@ Description: "MERTXCURR"
* insert common-numonly


Instance: MERDebug
InstanceOf: Measure
Title: "MERDebug"
Description: "MERDebug"
* id = "MERDebug"
* insert meas-common
* name = "MERDebug"
* title = "MERDebug"
* description = "MERDebug"
* url = "https://path-global-health.github.io/MERindicators/Measure/MERDebug"
* identifier[0].value = "MERDebug"
// only numerator
* scoring = $measure-scoring#cohort
* library[+] = Canonical(Debug)
* insert common-numonly
// Not using for now, will try evaluate library:
// https://build.fhir.org/ig/HL7/cqf-recommendations/OperationDefinition-cpg-library-evaluate.html

// Instance: MERDebug
// InstanceOf: Measure
// Title: "MERDebug"
// Description: "MERDebug"
// * id = "MERDebug"
// * insert meas-common
// * name = "MERDebug"
// * title = "MERDebug"
// * description = "MERDebug"
// * url = "https://path-global-health.github.io/MERindicators/Measure/MERDebug"
// * identifier[0].value = "MERDebug"
// // only numerator
// * scoring = $measure-scoring#cohort
// * library[+] = Canonical(Debug)
// * group[+]
// * code = $OpenHIE#cohort "cohort"
// * population[+]
// * description = "Initial Population"
// * code = $measure-population#initial-population
// * criteria.language = #text/cql
// * criteria.expression = "Initial Population"
// * population[+]
// * description = "Numerator-Exclusion"
// * code = $measure-population#numerator-exclusion
// * criteria.language = #text/cql
// * criteria.expression = "Numerator-Exclusion"
// * population[+]
// * description = "Numerator"
// * code = $measure-population#numerator
// * criteria.language = #text/cql
// * criteria.expression = "Numerator"
// * stratifier[+]
// * criteria.language = #text/cql
// * criteria.expression = "Stratifier"

1 change: 1 addition & 0 deletions input/fsh/terminology.fsh
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ Description: "Columbia International eHealth Laboratory (CIEL)"
* #1434 "Currently pregnant" // boolean
* #138405 "Human immunodeficiency virus (HIV) disease" // coded
* #160119 "CURRENTLY TAKING ARV" // q&a
* #116128 "Malaria" // For tests from OMRS IG
// WIP
* #86663 "Zidovudine"
* #74807 "Didanosine"
Expand Down
6 changes: 5 additions & 1 deletion input/fsh/test-ciel0.fsh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,11 @@ Description: "PatientCIEL"
* gender = #female
* birthDate = "1985-01-01"
* identifier.use = #official
* identifier.extension[OMRSPatientIdentifierLocationExtension].valueReference = Reference(LocationCIEL)
// * identifier.extension[OMRSPatientIdentifierLocationExtension].url = "http://fhir.openmrs.org/ext/patient/identifier#location"
// * identifier.extension[OMRSPatientIdentifierLocationExtension].valueReference = Reference(LocationCIEL)
// have to fix the openmrs ig patient.identififer.extension.url until its fixed in that ig
* identifier.extension.url = "http://fhir.openmrs.org/ext/patient/identifier#location"
* identifier.extension.valueReference = Reference(LocationCIEL)
* type = "Location"
* display = "Inpatient Ward"
* identifier.type = http://terminology.hl7.org/CodeSystem/v2-0203#MR
Expand Down
27 changes: 14 additions & 13 deletions test/scripts/_runload.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,20 +14,21 @@ export FHIR="http://localhost:8080/fhir"
# export FHIR="http://ryzen.local:8080/fhir"

export HEADER="Content-Type: application/fhir+json"
export output="../../../output"
export OUTPUT="@../../../output"
export output="../../output"
export OUTPUT="@../../output"
export SCRIPTS="../test/scripts"

function confirmation {
printf '\nDo you wish to continue (y/n)? '
read answer
# function confirmation {
# printf '\nDo you wish to continue (y/n)? '
# read answer

if [ "$answer" != "${answer#[Yy]}" ] ;then
echo ""
else
echo ""
exit
fi
}
# if [ "$answer" != "${answer#[Yy]}" ] ;then
# echo ""
# else
# echo ""
# exit
# fi
# }

function Loader() {
cd ${output}
Expand All @@ -38,7 +39,7 @@ function Loader() {
curl -s -X PUT -H "$HEADER" --data @${FILE} $FHIR/$1/${EYED} | jq .

done
cd ../input/tests/server
cd ${SCRIPTS}
}

# on some servers this isn't needed, but it is included here
Expand Down

0 comments on commit f94dc0b

Please sign in to comment.