Context
MSF have requested the following custom logic for populating the "Consultation Rank" DE in DHIS2 (unique ID: VKLjFBla0PL):
"Fill DHIS2 DE with the rank BY VISIT of the current NCD consultation"
Ludovic explained this logic further:
The idea is to fill DHIS2 with 1 when it is the first visit - in principle it should be the baseline visit. The we may have follow-up visits (cf. form F50) with rank 2 to n. First challenge: possibly a follow-up form could be filled before a baseline form; this is a error from the user but it can happen; in this case, the first follow-up will have 1 as rank. Second issue: we might have patients that come back after a first cycle of follow-up (baseline, follow-up then exit). In this case we need to differentiate between the first and second cycle. This may be done using the visit.
Specific Request
TBD
Test Data
- Create a new patient in OMRS
- Create a new visit for the patient
- Create a Baseline encounter for the patient using F49
- Create a Follow-up encounter for the patient using F50
- Complete the Visit
- Create a NEW visit for the patient
- Create a Baseline encounter for the patient using F49
- Create a Follow-up encounter for the patient using F50
- Complete the Visit
- Trigger
wf2-omrs-dhis2 workflow
- Visit 1 Baseline data should have "Consultation Rank" = 1
- Visit 1 Follow-up data should have "Consultation Rank" = 2
- Visit 2 Baseline data should have "Consultation Rank" = 1
- Visit 2 Follow-up data should have "Consultation Rank" = 2
Changes
In Events Mapping Step
-
Add custom logic mapping as per mapping spec for F49 - F50 forms.
-
Mapping-specs can be found here in sheets named after the form names.
-
adaptor: [common@2.1.1]
-
credentials: LP: ..., FN: OpenMRS Demo
In Create Events Step
When Get Encounters run successful, then Create events should run
successful. Troubleshoot any error that might be caused by the new mappings
- adaptor: [dhis2@5.0.1]
- credentials:
LP: ..., FN: MSF DHIS2 UAT
Important
Pre-deployment Checklist (For consultants)
Before closing off this issue, ensure the following items are checked:
Context
MSF have requested the following custom logic for populating the "Consultation Rank" DE in DHIS2 (unique ID: VKLjFBla0PL):
"Fill DHIS2 DE with the rank BY VISIT of the current NCD consultation"
Ludovic explained this logic further:
Specific Request
TBD
Test Data
wf2-omrs-dhis2workflowChanges
In
Events MappingStepAdd custom logic mapping as per mapping spec for
F49 - F50forms.Mapping-specs can be found here in sheets named after the form names.
adaptor: [common@2.1.1]
credentials:
LP: ...,FN: OpenMRS DemoIn
Create EventsStepWhen
Get Encountersrun successful, thenCreate eventsshould runsuccessful. Troubleshoot any error that might be caused by the new mappings
LP: ...,FN: MSF DHIS2 UATImportant
video
Pre-deployment Checklist (For consultants)
Before closing off this issue, ensure the following items are checked:
workflow, run the entire test suite and ensure that it passes
the adaptor versions that are specified in the
cache registry.
projectState and version the release
docs, diagrams, and/or test suite need to be updated.
and create a PR for MSF to review.