From 041089d364d59f3f5b1ccc26aa98ae4ce750e6b1 Mon Sep 17 00:00:00 2001 From: AJAL ODORA JONATHAN <43242517+ODORA0@users.noreply.github.com> Date: Mon, 21 Mar 2022 15:51:27 +0300 Subject: [PATCH 01/23] OHRI-705 Patient Tracing Form with business rules --- src/packages/forms-registry.ts | 4 ++++ .../tabs/contact-tracing.component.tsx | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/packages/forms-registry.ts b/src/packages/forms-registry.ts index 77d0503b9..14f61c29a 100644 --- a/src/packages/forms-registry.ts +++ b/src/packages/forms-registry.ts @@ -18,6 +18,7 @@ import covid_outcome_form_v_1_0 from './covid/forms/outcome-form/1.0.json'; import covid_case_form_v_1_0 from './covid/forms/case-form/1.0.json'; import death_form_v_1_0 from './hiv/forms/care-and-treatment/death-form/1.0.json'; import transfer_out_v_1_0 from './hiv/forms/care-and-treatment/transfer-out/1.0.json'; +import patient_tracing_v_1_0 from './hiv/forms/care-and-treatment/patient-tracing/1.0.json'; export default { hiv: { @@ -46,6 +47,9 @@ export default { transfer_out: { '1.0': transfer_out_v_1_0, }, + patient_tracing: { + '1.0': patient_tracing_v_1_0, + }, }, covid: { covid_assessment: { diff --git a/src/pages/partner-notification-services/tabs/contact-tracing.component.tsx b/src/pages/partner-notification-services/tabs/contact-tracing.component.tsx index 484658a56..3de0c4031 100644 --- a/src/pages/partner-notification-services/tabs/contact-tracing.component.tsx +++ b/src/pages/partner-notification-services/tabs/contact-tracing.component.tsx @@ -69,7 +69,7 @@ const ContactTracingList: React.FC = ({ patientUuid }) Date: Mon, 21 Mar 2022 15:53:27 +0300 Subject: [PATCH 02/23] Add Patient Tracing form --- .../patient-tracing/1.0.json | 740 ++++++++++++++++++ 1 file changed, 740 insertions(+) create mode 100644 src/packages/hiv/forms/care-and-treatment/patient-tracing/1.0.json diff --git a/src/packages/hiv/forms/care-and-treatment/patient-tracing/1.0.json b/src/packages/hiv/forms/care-and-treatment/patient-tracing/1.0.json new file mode 100644 index 000000000..7c2027e9f --- /dev/null +++ b/src/packages/hiv/forms/care-and-treatment/patient-tracing/1.0.json @@ -0,0 +1,740 @@ +{ + "name":"Patient Tracing Form", + "pages":[ + { + "label":"Introduction", + "sections":[ + { + "label":"", + "isExpanded":"true", + "questions":[ + { + "type":"markdown", + "questionOptions":{ + "rendering":"markdown" + }, + "id":"fooMarkdown", + "value":[ + "**Use this form to:** Trace a patient who has missed an appointment or drug pick up " + ] + } + ] + } + ] + }, + { + "label":"Patient Tracing", + "sections":[ + { + "label":"Patient Tracing Details", + "isExpanded":"true", + "questions":[ + { + "label":"Contact date", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"160753AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "conceptMappings":[ + { + "type":"CIEL", + "value":"160753" + }, + { + "type":"CIEL", + "value":"160753" + }, + { + "type":"SNOMED-CT", + "value":"439771001" + }, + { + "type":"SNOMED-CT", + "value":"439771001" + } + ] + }, + "id":"contactDate", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [ + { + "type": "date", + "allowFutureDates": "false" + }, + { + "type": "js_expression", + "failsWhenExpression": "isDateBefore(myValue, '1980-01-01') || myValue >= today()" } + ] + } + ] + }, + { + "label":"Contact Method", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"59c023dd-eed2-4b11-8c34-b88e9439db3c", + "answers":[ + { + "concept":"166457AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Physical contact/client tracing", + "conceptMappings":[ + + ] + }, + { + "concept":"166458AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Telephone contact/client tracing", + "conceptMappings":[ + + ] + }, + { + "concept":"5622AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Other non-coded", + "conceptMappings":[ + { + "type":"PIH-Malawi", + "value":"6408" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"OTHER" + }, + { + "type":"PIH", + "value":"5622" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"OTHER" + }, + { + "type":"PIH-Malawi", + "value":"6408" + }, + { + "type":"SNOMED-MVP", + "value":"56221000105001" + }, + { + "type":"AMPATH", + "value":"5622" + }, + { + "type":"PIH", + "value":"5622" + }, + { + "type":"SNOMED-MVP", + "value":"56221000105001" + }, + { + "type":"CIEL", + "value":"5622" + }, + { + "type":"AMPATH", + "value":"5622" + }, + { + "type":"SNOMED-CT", + "value":"74964007" + } + ] + } + ] + }, + "id":"contactMethod", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [] + } + ] + } + ] + }, + { + "label":"Outcome Patient", + "isExpanded":"true", + "questions":[ + { + "label":"Contacted Successfully", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"911d08b4-b523-46e4-8b65-e6924e95d015", + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED-CT", + "value":"373066001" + }, + { + "type":"PIH-Malawi", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + } + ] + }, + { + "concept":"1066AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"No", + "conceptMappings":[ + { + "type":"PIH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"PIH", + "value":"1066" + } + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"SNOMED-CT", + "value":"261665006" + }, + { + "type":"PIH", + "value":"1067" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"UNKNOWN" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"PIH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + } + ] + } + ] + }, + "id":"patientContacted", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [] + } + ] + }, + { + "label":"Reasons for missing an appointment - coded", + "type":"obs", + "questionOptions":{ + "rendering":"select", + "concept":"76072178-3545-4eb4-b5d0-55f59134d46a", + "answers":[ + { + "concept":"52e74b91-ad02-4efe-9715-6bf332114a45", + "label":"Client could not get an off from work/school", + "conceptMappings":[ + + ] + }, + { + "concept":"1b9a90ef-d7cb-4ff2-ba5f-0757463fae0b", + "label":"COVID-19 Restrictions", + "conceptMappings":[ + + ] + }, + { + "concept":"165610AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Exposure to COVID-19", + "conceptMappings":[ + + ] + }, + { + "concept":"1d7e550b-3252-4a34-87cf-50702aa8ff2b", + "label":"Had enough medications", + "conceptMappings":[ + + ] + }, + { + "concept":"160586AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Felt better and stopped taking medication", + "conceptMappings":[ + { + "type":"CIEL", + "value":"160586" + }, + { + "type":"SNOMED-CT", + "value":"397695000" + } + ] + }, + { + "concept":"5485AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Inpatient care or hospitalization", + "conceptMappings":[ + { + "type":"PIH", + "value":"1429" + }, + { + "type":"PIH", + "value":"1429" + }, + { + "type":"AMPATH", + "value":"5485" + }, + { + "type":"AMPATH", + "value":"5485" + }, + { + "type":"SNOMED-CT", + "value":"394656005" + }, + { + "type":"SNOMED-CT", + "value":"394656005" + }, + { + "type":"CIEL", + "value":"5485" + } + ] + }, + { + "concept":"162192AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Patient forgot to attend appointment", + "conceptMappings":[ + + ] + }, + { + "concept":"162888AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Patient was seen in another health center", + "conceptMappings":[ + + ] + }, + { + "concept":"124153AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Traveling", + "conceptMappings":[ + + ] + } + ] + }, + "id":"missAppCoded", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('patientContacted','1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA')" + }, + "validators": [] + } + ] + }, + { + "label":"Reason for Missing appointment", + "type":"obs", + "questionOptions":{ + "rendering":"textarea", + "concept":"159796AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "rows":"", + "conceptMappings":[ + { + "type":"CIEL", + "value":"159796" + }, + { + "type":"SNOMED-MVP", + "value":"1597961000105005" + }, + { + "type":"SNOMED-CT", + "value":"281399006" + }, + { + "type":"AMPATH", + "value":"6187" + } + ] + }, + "id":"reasonMissedApp", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('patientContacted','1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA')" + }, + "validators": [] + } + ] + }, + { + "label":"Expected Return Date", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"5096AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "weeksList":"", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"5096" + }, + { + "type":"AMPATH", + "value":"5096" + }, + { + "type":"PIH-Malawi", + "value":"5096" + }, + { + "type":"SNOMED-MVP", + "value":"50961000105000" + }, + { + "type":"CIEL", + "value":"5096" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"RETURN VISIT DATE" + }, + { + "type":"SNOMED-MVP", + "value":"50961000105000" + }, + { + "type":"PIH-Malawi", + "value":"5096" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"RETURN VISIT DATE" + }, + { + "type":"SNOMED-CT", + "value":"406543005" + } + ] + }, + "id":"expectedReturnDate", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('patientContacted','1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA')" + }, + "validators": [] + } + ] + } + ] + } + ] + }, + { + "label":"Outcome", + "sections":[ + { + "label":"Final Outcome Patient", + "isExpanded":"true", + "questions":[ + { + "label":"Final Outcome reached (After successful or multiple unsuccessful tracing attempts)", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"eeba884c-67fc-4f03-be2e-8dd3eb64ae10", + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED-CT", + "value":"373066001" + }, + { + "type":"PIH-Malawi", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + } + ] + }, + { + "concept":"1066AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"No", + "conceptMappings":[ + { + "type":"PIH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"PIH", + "value":"1066" + } + ] + } + ] + }, + "id":"finalOutcomeReached", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [] + } + ] + }, + { + "label":"Final tracing outcome - Patient", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"bc45edbd-11e7-4888-ad7d-4ec3dd8cdcf6", + "answers":[ + { + "concept":"160432AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Dead (Create a Death Form)", + "conceptMappings":[ + + ] + }, + { + "concept":"f3bd5aaf-c2be-4194-917f-dd7768d9e517", + "label":"Undocumented/Silent transfer-out (Create a Transfer-Out Form)", + "conceptMappings":[ + + ] + }, + { + "concept":"ac4f3fd1-8a2a-4c5e-a335-3f675b82dd78", + "label":"Refused (stopped) treatment (Update ART Therapy Form)", + "conceptMappings":[ + + ] + }, + { + "concept":"5240AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Interruption in Treatment (Lost to follow-up)", + "conceptMappings":[ + + ] + }, + { + "concept":"160119AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Currently taking ARV", + "conceptMappings":[ + + ] + } + ] + }, + "id":"finalTracingPatient", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('finalOutcomeReached','1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA')" + }, + "validators": [] + } + ] + } + ] + } + ] + }, + { + "label":"Notes", + "sections":[ + { + "label":"Contact tracking notes", + "isExpanded":"true", + "questions":[ + { + "label":"Notes", + "type":"obs", + "questionOptions":{ + "rendering":"textarea", + "concept":"165095AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "rows":"", + "conceptMappings":[ + { + "type":"CIEL", + "value":"165095" + } + ] + }, + "id":"contactTracingNotes" + } + ] + } + ] + } + ], + "availableIntents": [ + { + "intent": "*", + "display": "Patient Tracing Form" + } + ], + "processor":"EncounterFormProcessor", + "uuid":"xxxx", + "referencedForms":[], + "encounterType": "0cd5d4cb-204e-419a-9dd7-1e18e939ce4c", + "allowUnspecifiedAll": true + } \ No newline at end of file From c43e23fa45e127327cb0aceb50ea29c1f616e537 Mon Sep 17 00:00:00 2001 From: Samuel Male Date: Tue, 22 Mar 2022 12:39:21 +0300 Subject: [PATCH 03/23] OHRI-640: Configure encounter widget to pickup notes --- src/ohri-patient-dashboards-config.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ohri-patient-dashboards-config.json b/src/ohri-patient-dashboards-config.json index 0fdc67208..a5bb92843 100644 --- a/src/ohri-patient-dashboards-config.json +++ b/src/ohri-patient-dashboards-config.json @@ -9,11 +9,11 @@ "programs-summary-dashboard", "allergies-summary-dashboard", "attachments-results-summary-dashboard", - "drug-orders-summary-dashboard", - "encounters-summary-dashboard" + "drug-orders-summary-dashboard" ] } - } + }, + "notesConceptUuids": ["161011AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA"] }, "@openmrs/esm-patient-banner-app": { "extensionSlots": { From 3dec20bd2a54636f58c0af5d0f79d5bb33df709a Mon Sep 17 00:00:00 2001 From: AJAL ODORA JONATHAN <43242517+ODORA0@users.noreply.github.com> Date: Tue, 22 Mar 2022 12:42:59 +0300 Subject: [PATCH 04/23] OHRI-752 Patient Tracing tab added under Partner Notification Section --- ...artner-notification-services.component.tsx | 4 + .../tabs/patient-tracing.component.tsx | 81 +++++++++++++++++++ 2 files changed, 85 insertions(+) create mode 100644 src/pages/partner-notification-services/tabs/patient-tracing.component.tsx diff --git a/src/pages/partner-notification-services/partner-notification-services.component.tsx b/src/pages/partner-notification-services/partner-notification-services.component.tsx index 5c870d2d3..55579699c 100644 --- a/src/pages/partner-notification-services/partner-notification-services.component.tsx +++ b/src/pages/partner-notification-services/partner-notification-services.component.tsx @@ -3,6 +3,7 @@ import { Tabs, Tab } from 'carbon-components-react'; import styles from '../common.scss'; import PartnerNotificationList from './tabs/partner-notification.component'; import ContactTracingList from './tabs/contact-tracing.component'; +import PatientTracingList from './tabs/patient-tracing.component'; interface OverviewListProps { patientUuid: string; @@ -17,6 +18,9 @@ const PartnerNotificationServices: React.FC = ({ patientUuid + + + ); diff --git a/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx b/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx new file mode 100644 index 000000000..e975ab0dd --- /dev/null +++ b/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx @@ -0,0 +1,81 @@ +import React, { useEffect, useState } from 'react'; +import { useTranslation } from 'react-i18next'; +import EmptyState from '../../../components/empty-state/empty-state.component'; +import EncounterList, { + EncounterListColumn, + getObsFromEncounter, +} from '../../../components/encounter-list/encounter-list.component'; +import { deathFormEncounterType_UUID } from '../../../constants'; + +interface PatientTracingListProps { + patientUuid: string; +} + +const columnsLab: EncounterListColumn[] = [ + { + key: 'contactDate', + header: 'Contact Date', + getValue: encounter => { + return getObsFromEncounter(encounter, true); + }, + }, + { + key: 'contactMethod', + header: 'Contact Method', + getValue: encounter => { + return getObsFromEncounter(encounter, true); + }, + }, + { + key: 'contactOutcome', + header: 'Contact Outcome', + getValue: encounter => { + return getObsFromEncounter(encounter, true); + }, + }, + + { + key: 'actions', + header: 'Actions', + getValue: encounter => { + const baseActions = [ + { + form: { name: 'patient_tracing', package: 'hiv' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'View Details', + mode: 'view', + }, + { + form: { name: 'patient_tracing', package: 'hiv' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'Edit Details', + mode: 'edit', + }, + ]; + return baseActions; + }, + }, +]; + +const PatientTracingList: React.FC = ({ patientUuid }) => { + const { t } = useTranslation(); + + const headerTitle = t('patientTracing', 'Patient Tracing'); + const displayText = t('patientTracing', 'Patient Tracing'); + + return ( + + ); +}; + +export default PatientTracingList; From 75b2daa535f94d670e9e681e724753a662c4d57e Mon Sep 17 00:00:00 2001 From: AJAL ODORA JONATHAN <43242517+ODORA0@users.noreply.github.com> Date: Tue, 22 Mar 2022 20:01:27 +0300 Subject: [PATCH 05/23] Add Patient tab --- .../tabs/patient-tracing.component.tsx | 65 +------------------ 1 file changed, 3 insertions(+), 62 deletions(-) diff --git a/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx b/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx index e975ab0dd..483f818f0 100644 --- a/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx +++ b/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx @@ -1,64 +1,11 @@ import React, { useEffect, useState } from 'react'; import { useTranslation } from 'react-i18next'; import EmptyState from '../../../components/empty-state/empty-state.component'; -import EncounterList, { - EncounterListColumn, - getObsFromEncounter, -} from '../../../components/encounter-list/encounter-list.component'; -import { deathFormEncounterType_UUID } from '../../../constants'; interface PatientTracingListProps { patientUuid: string; } -const columnsLab: EncounterListColumn[] = [ - { - key: 'contactDate', - header: 'Contact Date', - getValue: encounter => { - return getObsFromEncounter(encounter, true); - }, - }, - { - key: 'contactMethod', - header: 'Contact Method', - getValue: encounter => { - return getObsFromEncounter(encounter, true); - }, - }, - { - key: 'contactOutcome', - header: 'Contact Outcome', - getValue: encounter => { - return getObsFromEncounter(encounter, true); - }, - }, - - { - key: 'actions', - header: 'Actions', - getValue: encounter => { - const baseActions = [ - { - form: { name: 'patient_tracing', package: 'hiv' }, - encounterUuid: encounter.uuid, - intent: '*', - label: 'View Details', - mode: 'view', - }, - { - form: { name: 'patient_tracing', package: 'hiv' }, - encounterUuid: encounter.uuid, - intent: '*', - label: 'Edit Details', - mode: 'edit', - }, - ]; - return baseActions; - }, - }, -]; - const PatientTracingList: React.FC = ({ patientUuid }) => { const { t } = useTranslation(); @@ -66,15 +13,9 @@ const PatientTracingList: React.FC = ({ patientUuid }) const displayText = t('patientTracing', 'Patient Tracing'); return ( - + <> + + ); }; From 0571bf2002f308baf156a017699a839291364e03 Mon Sep 17 00:00:00 2001 From: AJAL ODORA JONATHAN <43242517+ODORA0@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:44:03 +0300 Subject: [PATCH 06/23] OHRI-680 Patient Tracing Form and list added to the partner notification services --- src/constants.ts | 6 ++ .../tabs/patient-tracing.component.tsx | 70 ++++++++++++++++++- 2 files changed, 73 insertions(+), 3 deletions(-) diff --git a/src/constants.ts b/src/constants.ts index f714ab4dd..afb552ade 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -172,3 +172,9 @@ export const visitDate_UUID = '163137AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const receivingFacility_UUID = '162724AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const TransferOutDate_UUID = '160649AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const verified_UUID = '797e0073-1f3f-46b1-8b1a-8cdad134d2b3'; + +//Patient Tracing +export const ContactDate_UUID = '160753AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; +export const ContactMethod_UUID = '59c023dd-eed2-4b11-8c34-b88e9439db3c'; +export const ContactOutcome_UUID = 'bc45edbd-11e7-4888-ad7d-4ec3dd8cdcf6'; +export const PatientTracingEncounterType_UUID = '0cd5d4cb-204e-419a-9dd7-1e18e939ce4c'; diff --git a/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx b/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx index 483f818f0..27fcd8c95 100644 --- a/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx +++ b/src/pages/partner-notification-services/tabs/patient-tracing.component.tsx @@ -1,11 +1,69 @@ import React, { useEffect, useState } from 'react'; import { useTranslation } from 'react-i18next'; import EmptyState from '../../../components/empty-state/empty-state.component'; +import EncounterList, { + EncounterListColumn, + getObsFromEncounter, +} from '../../../components/encounter-list/encounter-list.component'; +import { + ContactDate_UUID, + ContactMethod_UUID, + ContactOutcome_UUID, + PatientTracingEncounterType_UUID, +} from '../../../constants'; interface PatientTracingListProps { patientUuid: string; } +const columnsLab: EncounterListColumn[] = [ + { + key: 'contactDate', + header: 'Contact Date', + getValue: encounter => { + return getObsFromEncounter(encounter, ContactDate_UUID, true); + }, + }, + { + key: 'contactMethod', + header: 'Contact Method', + getValue: encounter => { + return getObsFromEncounter(encounter, ContactMethod_UUID); + }, + }, + { + key: 'contactOutcome', + header: 'Contact Outcome', + getValue: encounter => { + return getObsFromEncounter(encounter, ContactOutcome_UUID); + }, + }, + + { + key: 'actions', + header: 'Actions', + getValue: encounter => { + const baseActions = [ + { + form: { name: 'patient_tracing', package: 'hiv' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'View Details', + mode: 'view', + }, + { + form: { name: 'patient_tracing', package: 'hiv' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'Edit Details', + mode: 'edit', + }, + ]; + return baseActions; + }, + }, +]; + const PatientTracingList: React.FC = ({ patientUuid }) => { const { t } = useTranslation(); @@ -13,9 +71,15 @@ const PatientTracingList: React.FC = ({ patientUuid }) const displayText = t('patientTracing', 'Patient Tracing'); return ( - <> - - + ); }; From 4aede59293cde3cf6880737db6d629a541ff906a Mon Sep 17 00:00:00 2001 From: AJAL ODORA JONATHAN <43242517+ODORA0@users.noreply.github.com> Date: Wed, 23 Mar 2022 13:37:23 +0300 Subject: [PATCH 07/23] OHRI-742 Enrollment form business rules updated --- src/constants.ts | 1 + .../service-enrolment/1.0.json | 4317 +++++++++-------- .../tabs/hiv-enrolment-tab.component.tsx | 15 + 3 files changed, 2245 insertions(+), 2088 deletions(-) diff --git a/src/constants.ts b/src/constants.ts index afb552ade..07b781a46 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -53,6 +53,7 @@ export const studyPopulationTypeConcept = 'd3d4ae96-8c8a-43db-a9dc-dac951f5dcb3' export const dateOfHIVDiagnosisConcept = '160554AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const entryPointConcept = '160540AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const re_enrolmentDateConcept = '20efadf9-86d3-4498-b3ab-7da4dad9c429'; +export const otherEntryPoint = '161011AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; // Clinical visit export const clinicalVisitEncounterType = 'cb0a65a7-0587-477e-89b9-cf2fd144f1d4'; diff --git a/src/packages/hiv/forms/care-and-treatment/service-enrolment/1.0.json b/src/packages/hiv/forms/care-and-treatment/service-enrolment/1.0.json index 89826070f..4d1a1fb2a 100644 --- a/src/packages/hiv/forms/care-and-treatment/service-enrolment/1.0.json +++ b/src/packages/hiv/forms/care-and-treatment/service-enrolment/1.0.json @@ -1,2108 +1,2249 @@ { - "name": "Service Enrolment Form", - "pages": [ - { - "label": "Introduction", - "sections": [ - { - "label": "", - "isExpanded": "true", - "questions": [ - { - "type": "markdown", - "questionOptions": { - "rendering": "markdown" - }, - "id": "fooMarkdown", - "value": [ - "**Use this form to:** Enrolment/Re-enrol a client for HIV Care" - ] + "name":"Service Enrolment Form", + "pages":[ + { + "label":"Introduction", + "sections":[ + { + "label":"", + "isExpanded":"true", + "questions":[ + { + "type":"markdown", + "questionOptions":{ + "rendering":"markdown" + }, + "id":"fooMarkdown", + "value":[ + "**Use this form to:** Enrolment/Re-enrol a client for HIV Care" + ] + } + ] + } + ] + }, + { + "label":"Client Profile", + "sections":[ + { + "label":"Client Details", + "isExpanded":"true", + "questions":[ + { + "label":"Enrolment Date", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"160555AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + }, + "validators":[ + { + "type":"date", + "allowFutureDates":"false" + }, + { + "type":"js_expression", + "failsWhenExpression":"myValue > today()" + } + ] + } + ], + "id":"hivEnrolmentDate" + }, + { + "label":"Unique ID", + "type":"obs", + "questionOptions":{ + "rendering":"text", + "concept":"162576AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + }, + "validators":[ + { + "type":"js_expression", + "failsWhenExpression":"isEmpty(patientIdentifier)" + } + ] + } + ], + "id":"patientIdentifier" + }, + { + "label":"Other Unique ID", + "type":"obs", + "questionOptions":{ + "rendering":"text", + "concept":"162727AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"otherUniquePatientIdentifier" + }, + { + "label":"Patient Type at Enrolment", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"83e40f2c-c316-43e6-a12e-20a338100281", + "answers":[ + { + "concept":"163532AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Mother enrolled in PMTCT program", + "conceptMappings":[ + + ] + }, + { + "concept":"159833AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Re-enroll", + "conceptMappings":[ + + ] + }, + { + "concept":"160563AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Transfer in", + "conceptMappings":[ + + ] + }, + { + "concept":"164144AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"New client", + "conceptMappings":[ + + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"false", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"clientDescription" + }, + { + "label":"Population Category", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"166432AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "answers":[ + { + "concept":"166431AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Key population", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"385436007" + } + ] + }, + { + "concept":"166430AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"General population", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"385436007" + } + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"clientPopulationCategory" + }, + { + "label":"Key/Priority Population Type", + "type":"obs", + "questionOptions":{ + "rendering":"checkbox", + "concept":"d3d4ae96-8c8a-43db-a9dc-dac951f5dcb3", + "answers":[ + { + "concept":"63ea75cb-205f-4e7b-9ede-5f9b8a4dda9f", + "label":"Migrant Workers", + "conceptMappings":[ + + ] + }, + { + "concept":"b282bb08-62a7-42c2-9bea-8751c267d13e", + "label":"Uniformed Forces", + "conceptMappings":[ + + ] + }, + { + "concept":"22b202fc-67de-4af9-8c88-46e22559d4b2", + "label":"Transgender Persons", + "conceptMappings":[ + + ] + }, + { + "concept":"678f3144-302f-493e-ba22-7ec60a84732a", + "label":"Adolescent Girls & Young Women", + "conceptMappings":[ + + ] + }, + { + "concept":"def00c73-f6d5-42fb-bcec-0b192b5be22d", + "label":"Fisher Folk", + "conceptMappings":[ + + ] + }, + { + "concept":"8da9bf92-22f6-40be-b468-1ad08de7d457", + "label":"Prisoners", + "conceptMappings":[ + + ] + }, + { + "concept":"dc1058ea-4edd-4780-aeaa-a474f7f3a437", + "label":"Refugees", + "conceptMappings":[ + + ] + }, + { + "concept":"160578AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Male who has sex with men", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"266974005" + } + ] + }, + { + "concept":"160579AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Sex worker", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"53713009" + } + ] + }, + { + "concept":"162198AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Long distance truck driver", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"87447002" } + ] + }, + { + "concept":"c038bff0-8e33-408c-b51f-7fb6448d2f6c", + "label":"People Who Inject Drugs", + "conceptMappings":[ + + ] + }, + { + "concept":"365371fd-0106-4a53-abc4-575e3d65d372", + "label":"People With Disability", + "conceptMappings":[ + + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"isEmpty(clientPopulationCategory) || clientPopulationCategory !== '166431AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + }, + "validators":[ + ] - } + } + ], + "id":"keyPopulationType" + }, + { + "label":"Entry Point", + "type":"obs", + "questionOptions":{ + "rendering":"select", + "concept":"160540AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "answers":[ + { + "concept":"162223AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Voluntary male circumcision clinic", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"257585005" + } + ] + }, + { + "concept":"161359AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Private home-based care", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"66280005" + } + ] + }, + { + "concept":"5622AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Other", + "conceptMappings":[ + { + "type":"PIH-Malawi", + "value":"6408" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"OTHER" + }, + { + "type":"SNOMED-MVP", + "value":"56221000105001" + }, + { + "type":"PIH", + "value":"5622" + }, + { + "type":"AMPATH", + "value":"5622" + }, + { + "type":"SNOMED-CT", + "value":"74964007" + } + ] + }, + { + "concept":"160549AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Adolescent outreach program", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"43741000" + }, + { + "type":"PIH", + "value":"1789" + } + ] + }, + { + "concept":"160547AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Private company", + "conceptMappings":[ + { + "type":"PIH", + "value":"1787" + }, + { + "type":"SNOMED-CT", + "value":"43741000" + } + ] + }, + { + "concept":"160545AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Outreach program", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"43741000" + }, + { + "type":"PIH", + "value":"1785" + } + ] + }, + { + "concept":"160543AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Community-based organization", + "conceptMappings":[ + { + "type":"PIH", + "value":"1741" + }, + { + "type":"SNOMED-CT", + "value":"43741000" + } + ] + }, + { + "concept":"160542AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Outpatient department", + "conceptMappings":[ + { + "type":"PIH", + "value":"1651" + }, + { + "type":"AMPATH", + "value":"1965" + }, + { + "type":"SNOMED-CT", + "value":"33022008" + } + ] + }, + { + "concept":"160537AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Pediatric inpatient service", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"398156002" + } + ] + }, + { + "concept":"160539AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Voluntary counseling and testing program", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"2047" + }, + { + "type":"PIH", + "value":"1649" + } + ] + }, + { + "concept":"159937AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Maternal and child health program", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"2050" + } + ] + }, + { + "concept":"160564AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Vaccination service", + "conceptMappings":[ + { + "type":"PIH", + "value":"6714" + }, + { + "type":"SNOMED-CT", + "value":"284548004" + } + ] + }, + { + "concept":"160552AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Nutrition program", + "conceptMappings":[ + { + "type":"PIH", + "value":"1845" + }, + { + "type":"SNOMED-CT", + "value":"386373004" + } + ] + }, + { + "concept":"160550AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Sex worker outreach program", + "conceptMappings":[ + { + "type":"PIH", + "value":"1790" + }, + { + "type":"SNOMED-CT", + "value":"43741000" + } + ] + }, + { + "concept":"160548AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Intravenous venous drug user outreach program", + "conceptMappings":[ + { + "type":"PIH", + "value":"1788" + }, + { + "type":"SNOMED-CT", + "value":"43741000" + } + ] + }, + { + "concept":"160546AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Sexually transmitted infection program/clinic", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"25681007" + }, + { + "type":"PIH", + "value":"1786" + } + ] + }, + { + "concept":"160544AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Under five clinic", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"702900003" + } + ] + }, + { + "concept":"160541AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Tuberculosis treatment program", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"401173007" + } + ] + }, + { + "concept":"160536AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Adult inpatient service", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"398156002" + } + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"enrollmentMethod" + }, + { + "label":"Entry Point - Other", + "type":"obs", + "questionOptions":{ + "rendering":"text", + "concept":"161011AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "conceptMappings":[ + { + "type": "CIEL", + "value": "161011" + } + ] + }, + "id":"otherEntryPoint", + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"!includes('enrollmentMethod','5622AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA')" + } + } + ] + } ] - }, - { - "label": "Client Profile", - "sections": [ - { - "label": "Client Details", - "isExpanded": "true", - "questions": [ - { - "label": "Enrolment Date", - "type": "obs", - "questionOptions": { - "rendering": "date", - "concept": "160555AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - }, - "validators": [ - { - "type": "date", - "allowFutureDates": "false" - }, - { - "type": "js_expression", - "failsWhenExpression": "myValue > today()" - } - ] - } - ], - "id": "hivEnrolmentDate" - }, - { - "label": "Unique ID", - "type": "obs", - "questionOptions": { - "rendering": "text", - "concept": "162576AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - }, - "validators": [ - { - "type": "js_expression", - "failsWhenExpression": "isEmpty(patientIdentifier)" - } - ] - } - ], - "id": "patientIdentifier" - }, - { - "label": "Other Unique ID", - "type": "obs", - "questionOptions": { - "rendering": "text", - "concept": "162727AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "otherUniquePatientIdentifier" - }, - { - "label": "Patient Type at Enrolment", - "type": "obs", - "questionOptions": { - "rendering": "radio", - "concept": "83e40f2c-c316-43e6-a12e-20a338100281", - "answers": [ - { - "concept": "163532AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Mother enrolled in PMTCT program", - "conceptMappings": [] - }, - { - "concept": "159833AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Re-enroll", - "conceptMappings": [] - }, - { - "concept": "160563AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Transfer in", - "conceptMappings": [] - }, - { - "concept": "164144AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "New client", - "conceptMappings": [] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "false", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "clientDescription" - }, - { - "label": "Population Category", - "type": "obs", - "questionOptions": { - "rendering": "radio", - "concept": "166432AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "answers": [ - { - "concept": "166431AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Key population", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "385436007" - } - ] - }, - { - "concept": "166430AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "General population", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "385436007" - } - ] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "clientPopulationCategory" - }, - { - "label": "Key/Priority Population Type", - "type": "obs", - "questionOptions": { - "rendering": "checkbox", - "concept": "d3d4ae96-8c8a-43db-a9dc-dac951f5dcb3", - "answers": [ - { - "concept": "63ea75cb-205f-4e7b-9ede-5f9b8a4dda9f", - "label": "Migrant Workers", - "conceptMappings": [] - }, - { - "concept": "b282bb08-62a7-42c2-9bea-8751c267d13e", - "label": "Uniformed Forces", - "conceptMappings": [] - }, - { - "concept": "22b202fc-67de-4af9-8c88-46e22559d4b2", - "label": "Transgender Persons", - "conceptMappings": [] - }, - { - "concept": "678f3144-302f-493e-ba22-7ec60a84732a", - "label": "Adolescent Girls & Young Women", - "conceptMappings": [] - }, - { - "concept": "def00c73-f6d5-42fb-bcec-0b192b5be22d", - "label": "Fisher Folk", - "conceptMappings": [] - }, - { - "concept": "8da9bf92-22f6-40be-b468-1ad08de7d457", - "label": "Prisoners", - "conceptMappings": [] - }, - { - "concept": "dc1058ea-4edd-4780-aeaa-a474f7f3a437", - "label": "Refugees", - "conceptMappings": [] - }, - { - "concept": "160578AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Male who has sex with men", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "266974005" - } - ] - }, - { - "concept": "160579AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Sex worker", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "53713009" - } - ] - }, - { - "concept": "162198AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Long distance truck driver", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "87447002" - } - ] - }, - { - "concept": "c038bff0-8e33-408c-b51f-7fb6448d2f6c", - "label": "People Who Inject Drugs", - "conceptMappings": [] - }, - { - "concept": "365371fd-0106-4a53-abc4-575e3d65d372", - "label": "People With Disability", - "conceptMappings": [] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "isEmpty(clientPopulationCategory) || clientPopulationCategory !== '166431AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - }, - "validators": [] - } - ], - "id": "keyPopulationType" - }, - { - "label": "Entry Point", - "type": "obs", - "questionOptions": { - "rendering": "select", - "concept": "160540AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "answers": [ - { - "concept": "162223AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Voluntary male circumcision clinic", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "257585005" - } - ] - }, - { - "concept": "161359AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Private home-based care", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "66280005" - } - ] - }, - { - "concept": "5622AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Other", - "conceptMappings": [ - { - "type": "PIH-Malawi", - "value": "6408" - }, - { - "type": "org.openmrs.module.mdrtb", - "value": "OTHER" - }, - { - "type": "SNOMED-MVP", - "value": "56221000105001" - }, - { - "type": "PIH", - "value": "5622" - }, - { - "type": "AMPATH", - "value": "5622" - }, - { - "type": "SNOMED-CT", - "value": "74964007" - } - ] - }, - { - "concept": "160549AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Adolescent outreach program", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "43741000" - }, - { - "type": "PIH", - "value": "1789" - } - ] - }, - { - "concept": "160547AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Private company", - "conceptMappings": [ - { - "type": "PIH", - "value": "1787" - }, - { - "type": "SNOMED-CT", - "value": "43741000" - } - ] - }, - { - "concept": "160545AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Outreach program", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "43741000" - }, - { - "type": "PIH", - "value": "1785" - } - ] - }, - { - "concept": "160543AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Community-based organization", - "conceptMappings": [ - { - "type": "PIH", - "value": "1741" - }, - { - "type": "SNOMED-CT", - "value": "43741000" - } - ] - }, - { - "concept": "160542AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Outpatient department", - "conceptMappings": [ - { - "type": "PIH", - "value": "1651" - }, - { - "type": "AMPATH", - "value": "1965" - }, - { - "type": "SNOMED-CT", - "value": "33022008" - } - ] - }, - { - "concept": "160537AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Pediatric inpatient service", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "398156002" - } - ] - }, - { - "concept": "160539AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Voluntary counseling and testing program", - "conceptMappings": [ - { - "type": "AMPATH", - "value": "2047" - }, - { - "type": "PIH", - "value": "1649" - } - ] - }, - { - "concept": "159937AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Maternal and child health program", - "conceptMappings": [ - { - "type": "AMPATH", - "value": "2050" - } - ] - }, - { - "concept": "160564AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Vaccination service", - "conceptMappings": [ - { - "type": "PIH", - "value": "6714" - }, - { - "type": "SNOMED-CT", - "value": "284548004" - } - ] - }, - { - "concept": "160552AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Nutrition program", - "conceptMappings": [ - { - "type": "PIH", - "value": "1845" - }, - { - "type": "SNOMED-CT", - "value": "386373004" - } - ] - }, - { - "concept": "160550AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Sex worker outreach program", - "conceptMappings": [ - { - "type": "PIH", - "value": "1790" - }, - { - "type": "SNOMED-CT", - "value": "43741000" - } - ] - }, - { - "concept": "160548AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Intravenous venous drug user outreach program", - "conceptMappings": [ - { - "type": "PIH", - "value": "1788" - }, - { - "type": "SNOMED-CT", - "value": "43741000" - } - ] - }, - { - "concept": "160546AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Sexually transmitted infection program/clinic", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "25681007" - }, - { - "type": "PIH", - "value": "1786" - } - ] - }, - { - "concept": "160544AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Under five clinic", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "702900003" - } - ] - }, - { - "concept": "160541AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Tuberculosis treatment program", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "401173007" - } - ] - }, - { - "concept": "160536AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Adult inpatient service", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "398156002" - } - ] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "enrollmentMethod" - }, - { - "label": "Entry Point - Other", - "type": "obs", - "questionOptions": { - "rendering": "text", - "concept": "5622AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "conceptMappings": [ - { - "type": "PIH-Malawi", - "value": "6408" - }, - { - "type": "org.openmrs.module.mdrtb", - "value": "OTHER" - }, - { - "type": "SNOMED-MVP", - "value": "56221000105001" - }, - { - "type": "PIH", - "value": "5622" - }, - { - "type": "AMPATH", - "value": "5622" - }, - { - "type": "SNOMED-CT", - "value": "74964007" - } - ] - }, - "id": "otherEntryPoint", - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ] - } + } + ] + }, + { + "label":"Transfer-In", + "sections":[ + { + "label":"Transfer-In", + "isExpanded":"true", + "questions":[ + { + "label":"Transferring Facility", + "type":"obs", + "questionOptions":{ + "rendering":"text", + "concept":"160535AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"locationTransferedFrom" + }, + { + "label":"Start ART Date", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"159599AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"artStartDate" + }, + { + "label":"Current ART Regimen", + "type":"obs", + "questionOptions":{ + "rendering":"select", + "concept":"dfbe256e-30ba-4033-837a-2e8477f2e7cd", + "answers":[ + { + "concept":"d8051638-0123-4322-a094-4a48adffdc37", + "label":"d4T + 3TC + NVP", + "conceptMappings":[ + + ] + }, + { + "concept":"67701961-f6c1-4ebf-a7f5-c2c5d25021a0", + "label":"TDF + FTC + EFV", + "conceptMappings":[ + + ] + }, + { + "concept":"083d46c5-dea7-49de-abd5-e16f252255a7", + "label":"TDF + FTC + DTG", + "conceptMappings":[ + + ] + }, + { + "concept":"36685ad3-a223-4c3c-b6ee-d8358432a600", + "label":"TDF + 3TC + NVP", + "conceptMappings":[ + + ] + }, + { + "concept":"380e5e7c-7c2f-4ba8-a93c-90b1e638dc2c", + "label":"TDF + 3TC + LPV/r", + "conceptMappings":[ + + ] + }, + { + "concept":"5f123dc8-c697-47f6-bc67-007322a9bb48", + "label":"TDF + 3TC + EFV", + "conceptMappings":[ + + ] + }, + { + "concept":"5679c813-cfed-4fb2-b252-d6149297e013", + "label":"TDF + 3TC + DTG + ETR + DRV + RTV", + "conceptMappings":[ + + ] + }, + { + "concept":"907d304b-ebc4-4387-8af8-2d2c92f82910", + "label":"TDF + 3TC + DTG + DRV + RTV", + "conceptMappings":[ + + ] + }, + { + "concept":"5a4587e2-de9e-4b99-9ea0-00717fa5605a", + "label":"TAF + 3TC + LPV/r", + "conceptMappings":[ + + ] + }, + { + "concept":"5f7da36e-1a83-4ede-ae6f-41aaa5304601", + "label":"TAF + 3TC + DTG", + "conceptMappings":[ + + ] + }, + { + "concept":"6b7cd8a1-77b3-4853-bbe7-ff6bf51c41c3", + "label":"TAF + 3TC + DRV/r", + "conceptMappings":[ + + ] + }, + { + "concept":"0fd8a042-81a3-4106-8470-63d29380d7d5", + "label":"RAL + 3TC + DRV + RTV + TDF", + "conceptMappings":[ + + ] + }, + { + "concept":"3ae355dd-fc83-43c6-9312-ebbb30b51bf7", + "label":"RAL + 3TC + DRV + RTV + AZT", + "conceptMappings":[ + + ] + }, + { + "concept":"1431d032-9eeb-46b3-84e5-79f0c19354d8", + "label":"RAL + 3TC + DRV + RTV", + "conceptMappings":[ + + ] + }, + { + "concept":"9e82e55d-dbbf-49a6-900c-d8ead9985b0a", + "label":"ETV + 3TC + DRV + RTV", + "conceptMappings":[ + + ] + }, + { + "concept":"e9540e20-1ba4-4573-b189-088f5fd9dc57", + "label":"AZT + 3TC + RAL", + "conceptMappings":[ + + ] + }, + { + "concept":"bafb40ca-b0c7-4366-bd8e-9eb923237c94", + "label":"AZT + 3TC + NVP", + "conceptMappings":[ + + ] + }, + { + "concept":"d2b1d784-a880-42a9-b0a6-19de2db7afd6", + "label":"AZT + 3TC + LPV/r", + "conceptMappings":[ + + ] + }, + { + "concept":"b1336ea0-3a87-4018-9fce-3a7a22d95d7d", + "label":"AZT + 3TC + EFV", + "conceptMappings":[ + + ] + }, + { + "concept":"f2247788-6d05-490d-ad04-64544c8020b7", + "label":"AZT + 3TC + DTG", + "conceptMappings":[ + + ] + }, + { + "concept":"60bec021-c05c-4ae9-93fe-b798c0bf82d2", + "label":"AZT + 3TC + DRV + RTV + RAL", + "conceptMappings":[ + + ] + }, + { + "concept":"62243dfe-6284-48a9-afcc-63149ac6d709", + "label":"AZT + 3TC + ATV/r", + "conceptMappings":[ + + ] + }, + { + "concept":"dc25af21-7816-44d8-92d2-3332c7db113a", + "label":"ABC + 3TC + RAL", + "conceptMappings":[ + + ] + }, + { + "concept":"98bec34c-608a-46ce-8f1a-3ee3b8b6f92b", + "label":"ABC + 3TC + NVP", + "conceptMappings":[ + { + "type":"CIEL", + "value":"162199" + } + ] + }, + { + "concept":"0da33711-7b3f-4997-bc9e-4a2445fbaf63", + "label":"ABC + 3TC + LPV/r", + "conceptMappings":[ + { + "type":"CIEL", + "value":"162200" + } + ] + }, + { + "concept":"70e9b78a-a6d8-49c2-8217-0ba57b05803a", + "label":"ABC + 3TC + EFV", + "conceptMappings":[ + { + "type":"CIEL", + "value":"162563" + } + ] + }, + { + "concept":"159db6bc-1303-4829-8fe4-32212751c934", + "label":"ABC + 3TC + DTG", + "conceptMappings":[ + { + "type":"CIEL", + "value":"165606" + } + ] + }, + { + "concept":"396d668b-b1e6-4997-b9b9-2d57f53c2321", + "label":"ABC + 3TC + DRVr", + "conceptMappings":[ + + ] + }, + { + "concept":"5bb0348b-fc27-460e-b6cd-df7a4a253372", + "label":"ABC + 3TC + DRV+RTV+RAL", + "conceptMappings":[ + + ] + }, + { + "concept":"f827ed18-f816-4cd0-b77c-28a0209c96c0", + "label":"ABC + 3TC + ATVr", + "conceptMappings":[ + + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"patientIdentifier" + }, + { + "label":"Transfer Documents", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"7962d0ed-0fb5-4580-8e46-6fd318091154", + "answers":[ + { + "concept":"163532AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Mother enrolled in prevention of maternal to child transmission (PMTCT) program", + "conceptMappings":[ + + ] + }, + { + "concept":"71a489e5-e393-4859-a2df-a3b14ea6b4bf", + "label":"Transfer-in with Records", + "conceptMappings":[ + + ] + }, + { + "concept":"a484d55e-dfc7-4791-82a4-eff8f21e26de", + "label":"Transfer-in without records", + "conceptMappings":[ + + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"transferInDoc" + }, + { + "label":"Date of Enrolment into HIV Care", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"163260AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"dateOfFirstVisit" + } + ] + } + ], + "behaviours":[ + { + "intent":"*", + "hide":{ + "hideWhenExpression":"isEmpty(clientDescription) || clientDescription !== '160563AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } + ] + }, + { + "label":"HIV Diagnosis", + "sections":[ + { + "label":"HIV Diagnosis", + "isExpanded":"true", + "questions":[ + { + "label":"Date Confirmed HIV Positive", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"160554AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + }, + "validators":[ + { + "type":"date", + "allowFutureDates":"false" + }, + { + "type":"js_expression", + "failsWhenExpression":"isDateBefore(myValue, '1980-01-01') || myValue >= today()" + } ] - } + } + ], + "id":"hivDiagnosisDate" + }, + { + "label":"Test Type", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"ca4953af-9ad4-4514-b54a-6832acd7cae9", + "answers":[ + { + "concept":"163722AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Rapid test for HIV", + "conceptMappings":[ + + ] + }, + { + "concept":"844AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"HIV DNA polymerase chain reaction", + "conceptMappings":[ + + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"diagnosticHivTestType" + }, + { + "label":"Test Location", + "type":"obs", + "questionOptions":{ + "rendering":"text", + "concept":"161549AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "answers":[ + { + "concept":"5622AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Other", + "conceptMappings":[ + { + "type":"PIH-Malawi", + "value":"6408" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"OTHER" + }, + { + "type":"SNOMED-MVP", + "value":"56221000105001" + }, + { + "type":"PIH", + "value":"5622" + }, + { + "type":"AMPATH", + "value":"5622" + }, + { + "type":"SNOMED-CT", + "value":"74964007" + } + ] + }, + { + "concept":"159671AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Provincial hospital", + "conceptMappings":[ + { + "type":"SNOMED-MVP", + "value":"1596711000105007" + }, + { + "type":"SNOMED-CT", + "value":"22232009" + }, + { + "type":"AMPATH", + "value":"6438" + } + ] + }, + { + "concept":"159670AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"sub-district hospital", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"6439" + }, + { + "type":"SNOMED-CT", + "value":"22232009" + }, + { + "type":"SNOMED-MVP", + "value":"1596701000105009" + } + ] + }, + { + "concept":"1274AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Moi teaching and referral hospital", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1274" + }, + { + "type":"SNOMED-CT", + "value":"405608006" + }, + { + "type":"SNOMED-MVP", + "value":"12741000105009" + } + ] + }, + { + "concept":"159662AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"district hospital", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"6437" + }, + { + "type":"SNOMED-CT", + "value":"22232009" + }, + { + "type":"SNOMED-MVP", + "value":"1596621000105007" + } + ] + }, + { + "concept":"1275AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Health center hospital", + "conceptMappings":[ + { + "type":"SNOMED-MVP", + "value":"12751000105006" + }, + { + "type":"SNOMED-CT", + "value":"22232009" + }, + { + "type":"AMPATH", + "value":"1275" + } + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"diagnosisLocation" + } ] - }, - { - "label": "Transfer-In", - "sections": [ - { - "label": "Transfer-In", - "isExpanded": "true", - "questions": [ - { - "label": "Transferring Facility", - "type": "obs", - "questionOptions": { - "rendering": "text", - "concept": "160535AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "locationTransferedFrom" - }, - { - "label": "Start ART Date", - "type": "obs", - "questionOptions": { - "rendering": "date", - "concept": "159599AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "artStartDate" - }, - { - "label": "Current ART Regimen", - "type": "obs", - "questionOptions": { - "rendering": "select", - "concept": "dfbe256e-30ba-4033-837a-2e8477f2e7cd", - "answers": [ - { - "concept": "d8051638-0123-4322-a094-4a48adffdc37", - "label": "d4T + 3TC + NVP", - "conceptMappings": [] - }, - { - "concept": "67701961-f6c1-4ebf-a7f5-c2c5d25021a0", - "label": "TDF + FTC + EFV", - "conceptMappings": [] - }, - { - "concept": "083d46c5-dea7-49de-abd5-e16f252255a7", - "label": "TDF + FTC + DTG", - "conceptMappings": [] - }, - { - "concept": "36685ad3-a223-4c3c-b6ee-d8358432a600", - "label": "TDF + 3TC + NVP", - "conceptMappings": [] - }, - { - "concept": "380e5e7c-7c2f-4ba8-a93c-90b1e638dc2c", - "label": "TDF + 3TC + LPV/r", - "conceptMappings": [] - }, - { - "concept": "5f123dc8-c697-47f6-bc67-007322a9bb48", - "label": "TDF + 3TC + EFV", - "conceptMappings": [] - }, - { - "concept": "5679c813-cfed-4fb2-b252-d6149297e013", - "label": "TDF + 3TC + DTG + ETR + DRV + RTV", - "conceptMappings": [] - }, - { - "concept": "907d304b-ebc4-4387-8af8-2d2c92f82910", - "label": "TDF + 3TC + DTG + DRV + RTV", - "conceptMappings": [] - }, - { - "concept": "5a4587e2-de9e-4b99-9ea0-00717fa5605a", - "label": "TAF + 3TC + LPV/r", - "conceptMappings": [] - }, - { - "concept": "5f7da36e-1a83-4ede-ae6f-41aaa5304601", - "label": "TAF + 3TC + DTG", - "conceptMappings": [] - }, - { - "concept": "6b7cd8a1-77b3-4853-bbe7-ff6bf51c41c3", - "label": "TAF + 3TC + DRV/r", - "conceptMappings": [] - }, - { - "concept": "0fd8a042-81a3-4106-8470-63d29380d7d5", - "label": "RAL + 3TC + DRV + RTV + TDF", - "conceptMappings": [] - }, - { - "concept": "3ae355dd-fc83-43c6-9312-ebbb30b51bf7", - "label": "RAL + 3TC + DRV + RTV + AZT", - "conceptMappings": [] - }, - { - "concept": "1431d032-9eeb-46b3-84e5-79f0c19354d8", - "label": "RAL + 3TC + DRV + RTV", - "conceptMappings": [] - }, - { - "concept": "9e82e55d-dbbf-49a6-900c-d8ead9985b0a", - "label": "ETV + 3TC + DRV + RTV", - "conceptMappings": [] - }, - { - "concept": "e9540e20-1ba4-4573-b189-088f5fd9dc57", - "label": "AZT + 3TC + RAL", - "conceptMappings": [] - }, - { - "concept": "bafb40ca-b0c7-4366-bd8e-9eb923237c94", - "label": "AZT + 3TC + NVP", - "conceptMappings": [] - }, - { - "concept": "d2b1d784-a880-42a9-b0a6-19de2db7afd6", - "label": "AZT + 3TC + LPV/r", - "conceptMappings": [] - }, - { - "concept": "b1336ea0-3a87-4018-9fce-3a7a22d95d7d", - "label": "AZT + 3TC + EFV", - "conceptMappings": [] - }, - { - "concept": "f2247788-6d05-490d-ad04-64544c8020b7", - "label": "AZT + 3TC + DTG", - "conceptMappings": [] - }, - { - "concept": "60bec021-c05c-4ae9-93fe-b798c0bf82d2", - "label": "AZT + 3TC + DRV + RTV + RAL", - "conceptMappings": [] - }, - { - "concept": "62243dfe-6284-48a9-afcc-63149ac6d709", - "label": "AZT + 3TC + ATV/r", - "conceptMappings": [] - }, - { - "concept": "dc25af21-7816-44d8-92d2-3332c7db113a", - "label": "ABC + 3TC + RAL", - "conceptMappings": [] - }, - { - "concept": "98bec34c-608a-46ce-8f1a-3ee3b8b6f92b", - "label": "ABC + 3TC + NVP", - "conceptMappings": [ - { - "type": "CIEL", - "value": "162199" - } - ] - }, - { - "concept": "0da33711-7b3f-4997-bc9e-4a2445fbaf63", - "label": "ABC + 3TC + LPV/r", - "conceptMappings": [ - { - "type": "CIEL", - "value": "162200" - } - ] - }, - { - "concept": "70e9b78a-a6d8-49c2-8217-0ba57b05803a", - "label": "ABC + 3TC + EFV", - "conceptMappings": [ - { - "type": "CIEL", - "value": "162563" - } - ] - }, - { - "concept": "159db6bc-1303-4829-8fe4-32212751c934", - "label": "ABC + 3TC + DTG", - "conceptMappings": [ - { - "type": "CIEL", - "value": "165606" - } - ] - }, - { - "concept": "396d668b-b1e6-4997-b9b9-2d57f53c2321", - "label": "ABC + 3TC + DRVr", - "conceptMappings": [] - }, - { - "concept": "5bb0348b-fc27-460e-b6cd-df7a4a253372", - "label": "ABC + 3TC + DRV+RTV+RAL", - "conceptMappings": [] - }, - { - "concept": "f827ed18-f816-4cd0-b77c-28a0209c96c0", - "label": "ABC + 3TC + ATVr", - "conceptMappings": [] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "patientIdentifier" - }, - { - "label": "Transfer Documents", - "type": "obs", - "questionOptions": { - "rendering": "radio", - "concept": "7962d0ed-0fb5-4580-8e46-6fd318091154", - "answers": [ - { - "concept": "163532AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Mother enrolled in prevention of maternal to child transmission (PMTCT) program", - "conceptMappings": [] - }, - { - "concept": "71a489e5-e393-4859-a2df-a3b14ea6b4bf", - "label": "Transfer-in with Records", - "conceptMappings": [] - }, - { - "concept": "a484d55e-dfc7-4791-82a4-eff8f21e26de", - "label": "Transfer-in without records", - "conceptMappings": [] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "transferInDoc" - }, - { - "label": "Date of Enrolment into HIV Care", - "type": "obs", - "questionOptions": { - "rendering": "date", - "concept": "163260AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "dateOfFirstVisit" + } + ], + "behaviours":[ + { + "intent":"*", + "hide":{ + "hideWhenExpression":"isEmpty(clientDescription) || clientDescription !== '159833AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } + ] + }, + { + "label":"Previous ARV/HAART Use", + "sections":[ + { + "label":"Previous ARV/HAART Use", + "isExpanded":"true", + "questions":[ + { + "label":"Use of Pre Exposure Prophylaxis (PrEP)", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"5d397775-0155-4033-95dc-edcec98e8190", + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" + } + ] + }, + { + "concept":"488b58ff-64f5-4f8a-8979-fa79940b1594", + "label":"No", + "conceptMappings":[ + + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + }, + { + "type":"PIH", + "value":"1067" } + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"previousUseOfPrep" + }, + { + "label":"Date Last Used", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"5af829e9-2427-4ed7-bb55-de4381610364" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"isEmpty(previousUseOfPrep) || previousUseOfPrep !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + }, + "validators":[ + { + "type":"date", + "allowFutureDates":"false" + }, + { + "type":"js_expression", + "failsWhenExpression":"isDateBefore(myValue, '1980-01-01') || myValue >= today()" + } ] - } - ], - "behaviours": [ - { - "intent": "*", - "hide": { - "hideWhenExpression": "isEmpty(clientDescription) || clientDescription !== '160563AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - } - } - ] - }, - { - "label": "HIV Diagnosis", - "sections": [ - { - "label": "HIV Diagnosis", - "isExpanded": "true", - "questions": [ - { - "label": "Date Confirmed HIV Positive", - "type": "obs", - "questionOptions": { - "rendering": "date", - "concept": "160554AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - }, - "validators": [ - { - "type": "date", - "allowFutureDates": "false" - }, - { - "type": "js_expression", - "failsWhenExpression": "isDateBefore(myValue, '1980-01-01') || myValue >= today()" - } - ] - } - ], - "id": "hivDiagnosisDate" - }, - { - "label": "Test Type", - "type": "obs", - "questionOptions": { - "rendering": "radio", - "concept": "ca4953af-9ad4-4514-b54a-6832acd7cae9", - "answers": [ - { - "concept": "163722AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Rapid test for HIV", - "conceptMappings": [] - }, - { - "concept": "844AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "HIV DNA polymerase chain reaction", - "conceptMappings": [] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "diagnosticHivTestType" - }, - { - "label": "Test Location", - "type": "obs", - "questionOptions": { - "rendering": "text", - "concept": "161549AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "answers": [ - { - "concept": "5622AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Other", - "conceptMappings": [ - { - "type": "PIH-Malawi", - "value": "6408" - }, - { - "type": "org.openmrs.module.mdrtb", - "value": "OTHER" - }, - { - "type": "SNOMED-MVP", - "value": "56221000105001" - }, - { - "type": "PIH", - "value": "5622" - }, - { - "type": "AMPATH", - "value": "5622" - }, - { - "type": "SNOMED-CT", - "value": "74964007" - } - ] - }, - { - "concept": "159671AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Provincial hospital", - "conceptMappings": [ - { - "type": "SNOMED-MVP", - "value": "1596711000105007" - }, - { - "type": "SNOMED-CT", - "value": "22232009" - }, - { - "type": "AMPATH", - "value": "6438" - } - ] - }, - { - "concept": "159670AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "sub-district hospital", - "conceptMappings": [ - { - "type": "AMPATH", - "value": "6439" - }, - { - "type": "SNOMED-CT", - "value": "22232009" - }, - { - "type": "SNOMED-MVP", - "value": "1596701000105009" - } - ] - }, - { - "concept": "1274AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Moi teaching and referral hospital", - "conceptMappings": [ - { - "type": "AMPATH", - "value": "1274" - }, - { - "type": "SNOMED-CT", - "value": "405608006" - }, - { - "type": "SNOMED-MVP", - "value": "12741000105009" - } - ] - }, - { - "concept": "159662AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "district hospital", - "conceptMappings": [ - { - "type": "AMPATH", - "value": "6437" - }, - { - "type": "SNOMED-CT", - "value": "22232009" - }, - { - "type": "SNOMED-MVP", - "value": "1596621000105007" - } - ] - }, - { - "concept": "1275AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Health center hospital", - "conceptMappings": [ - { - "type": "SNOMED-MVP", - "value": "12751000105006" - }, - { - "type": "SNOMED-CT", - "value": "22232009" - }, - { - "type": "AMPATH", - "value": "1275" - } - ] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "diagnosisLocation" + } + ], + "id":"datePrepLastUsed" + }, + { + "label":"Use of Post exposure prophylaxis (PEP)", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"8bfdc328-1970-446c-9d7b-97d62703801b", + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" } + ] + }, + { + "concept":"488b58ff-64f5-4f8a-8979-fa79940b1594", + "label":"No", + "conceptMappings":[ + + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + }, + { + "type":"PIH", + "value":"1067" + } + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"previousUseOfPep" + }, + { + "label":"Date Last Used", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"fbe937b6-a4ad-4ce5-9c43-002222fbabfb" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"isEmpty(previousUseOfPep) || previousUseOfPep !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + }, + "validators":[ + { + "type":"date", + "allowFutureDates":"false" + }, + { + "type":"js_expression", + "failsWhenExpression":"isDateBefore(myValue, '1980-01-01') || myValue >= today()" + } ] - } - ], - "behaviours": [ - { - "intent": "*", - "hide": { - "hideWhenExpression": "isEmpty(clientDescription) || clientDescription !== '159833AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - } - } - ] - }, - { - "label": "Previous ARV/HAART Use", - "sections": [ - { - "label": "Previous ARV/HAART Use", - "isExpanded": "true", - "questions": [ - { - "label": "Use of Pre Exposure Prophylaxis (PrEP)", - "type": "obs", - "questionOptions": { - "rendering": "radio", - "concept": "5d397775-0155-4033-95dc-edcec98e8190", - "answers": [ - { - "concept": "1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Yes", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1065" - }, - { - "type": "AMPATH", - "value": "1065" - }, - { - "type": "PIH", - "value": "1065" - }, - { - "type": "SNOMED CT", - "value": "CT: 373066001" - } - ] - }, - { - "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594", - "label": "No", - "conceptMappings": [] - }, - { - "concept": "1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Unknown", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1067" - }, - { - "type": "AMPATH", - "value": "1067" - }, - { - "type": "SNOMED CT", - "value": "CT: 261665006" - }, - { - "type": "PIH", - "value": "1067" - } - ] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "previousUseOfPrep" - }, - { - "label": "Date Last Used", - "type": "obs", - "questionOptions": { - "rendering": "date", - "concept": "5af829e9-2427-4ed7-bb55-de4381610364" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "isEmpty(previousUseOfPrep) || previousUseOfPrep !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - }, - "validators": [ - { - "type": "date", - "allowFutureDates": "false" - }, - { - "type": "js_expression", - "failsWhenExpression": "isDateBefore(myValue, '1980-01-01') || myValue >= today()" - } - ] - } - ], - "id": "datePrepLastUsed" - }, - { - "label": "Use of Post exposure prophylaxis (PEP)", - "type": "obs", - "questionOptions": { - "rendering": "radio", - "concept": "8bfdc328-1970-446c-9d7b-97d62703801b", - "answers": [ - { - "concept": "1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Yes", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1065" - }, - { - "type": "AMPATH", - "value": "1065" - }, - { - "type": "PIH", - "value": "1065" - }, - { - "type": "SNOMED CT", - "value": "CT: 373066001" - } - ] - }, - { - "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594", - "label": "No", - "conceptMappings": [] - }, - { - "concept": "1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Unknown", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1067" - }, - { - "type": "AMPATH", - "value": "1067" - }, - { - "type": "SNOMED CT", - "value": "CT: 261665006" - }, - { - "type": "PIH", - "value": "1067" - } - ] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "previousUseOfPep" - }, - { - "label": "Date Last Used", - "type": "obs", - "questionOptions": { - "rendering": "date", - "concept": "fbe937b6-a4ad-4ce5-9c43-002222fbabfb" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "isEmpty(previousUseOfPep) || previousUseOfPep !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - }, - "validators": [ - { - "type": "date", - "allowFutureDates": "false" - }, - { - "type": "js_expression", - "failsWhenExpression": "isDateBefore(myValue, '1980-01-01') || myValue >= today()" - } - ] - } - ], - "id": "datePepLastUsed" - }, - { - "label": "ARV Use for Management of Hepatitis", - "type": "obs", - "questionOptions": { - "rendering": "radio", - "concept": "906ed69c-949b-47b5-b469-2205f0da473a", - "answers": [ - { - "concept": "1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Yes", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1065" - }, - { - "type": "AMPATH", - "value": "1065" - }, - { - "type": "PIH", - "value": "1065" - }, - { - "type": "SNOMED CT", - "value": "CT: 373066001" - } - ] - }, - { - "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594", - "label": "No", - "conceptMappings": [] - }, - { - "concept": "1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Unknown", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1067" - }, - { - "type": "AMPATH", - "value": "1067" - }, - { - "type": "SNOMED CT", - "value": "CT: 261665006" - }, - { - "type": "PIH", - "value": "1067" - } - ] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "useOfArvs" - }, - { - "label": "Date Last Used", - "type": "obs", - "questionOptions": { - "rendering": "date", - "concept": "6a6cbda5-b155-4144-9ff9-ec3d1d1cd509" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "isEmpty(useOfArvs) || useOfArvs !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - }, - "validators": [ - { - "type": "date", - "allowFutureDates": "false" - }, - { - "type": "js_expression", - "failsWhenExpression": "isDateBefore(myValue, '1980-01-01') || myValue >= today()" - } - ] - } - ], - "id": "dateHepBLastUsed" - }, - { - "label": "ART Use for Prevention of Mother to Child Transmission of HIV", - "type": "obs", - "questionOptions": { - "rendering": "radio", - "concept": "163532AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "answers": [ - { - "concept": "1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Yes", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1065" - }, - { - "type": "AMPATH", - "value": "1065" - }, - { - "type": "PIH", - "value": "1065" - }, - { - "type": "SNOMED CT", - "value": "CT: 373066001" - } - ] - }, - { - "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594", - "label": "No", - "conceptMappings": [] - }, - { - "concept": "1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Unknown", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1067" - }, - { - "type": "AMPATH", - "value": "1067" - }, - { - "type": "SNOMED CT", - "value": "CT: 261665006" - }, - { - "type": "PIH", - "value": "1067" - } - ] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - } - } - ], - "id": "previousUseOfArt" - }, - { - "label": "Date Last Used", - "type": "obs", - "questionOptions": { - "rendering": "date", - "concept": "163782AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "isEmpty(previousUseOfArt) || previousUseOfArt !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - - }, - "validators": [ - { - "type": "date", - "allowFutureDates": "false" - }, - { - "type": "js_expression", - "failsWhenExpression": "isDateBefore(myValue, '1980-01-01') || myValue >= today()" - } - ] - } - ], - "id": "datePmtctLastUsed" + } + ], + "id":"datePepLastUsed" + }, + { + "label":"ARV Use for Management of Hepatitis", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"906ed69c-949b-47b5-b469-2205f0da473a", + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" + } + ] + }, + { + "concept":"488b58ff-64f5-4f8a-8979-fa79940b1594", + "label":"No", + "conceptMappings":[ + + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + }, + { + "type":"PIH", + "value":"1067" } + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"useOfArvs" + }, + { + "label":"Date Last Used", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"6a6cbda5-b155-4144-9ff9-ec3d1d1cd509" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"isEmpty(useOfArvs) || useOfArvs !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + }, + "validators":[ + { + "type":"date", + "allowFutureDates":"false" + }, + { + "type":"js_expression", + "failsWhenExpression":"isDateBefore(myValue, '1980-01-01') || myValue >= today()" + } ] + } + ], + "id":"dateHepBLastUsed" + }, + { + "label":"ART Use for Prevention of Mother to Child Transmission of HIV", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"163532AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" + } + ] + }, + { + "concept":"488b58ff-64f5-4f8a-8979-fa79940b1594", + "label":"No", + "conceptMappings":[ + + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + }, + { + "type":"PIH", + "value":"1067" + } + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + } + } + ], + "id":"previousUseOfArt" + }, + { + "label":"Date Last Used", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"163782AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"isEmpty(previousUseOfArt) || previousUseOfArt !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + }, + "validators":[ + { + "type":"date", + "allowFutureDates":"false" + }, + { + "type":"js_expression", + "failsWhenExpression":"isDateBefore(myValue, '1980-01-01') || myValue >= today()" + } + ] + } + ], + "id":"datePmtctLastUsed" + } + ] + }, + { + "label":"Previous ARV/HAART Drugs", + "isExpanded":"false", + "questions":[ + { + "label":"Nucleoside Reverse Transcriptase Inhibitors (NRTIS)", + "type":"obs", + "questionOptions":{ + "rendering":"checkbox", + "concept":"54e7ff9b-4d93-41ba-ad0b-cb5f565785f2", + "answers":[ + { + "concept":"5424AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Other antiretroviral drug", + "conceptMappings":[ + + ] + }, + { + "concept":"86663AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Zidovudine", + "conceptMappings":[ + + ] + }, + { + "concept":"84795AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Tenofovir", + "conceptMappings":[ + + ] + }, + { + "concept":"78643AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Lamivudine", + "conceptMappings":[ + + ] + }, + { + "concept":"75628AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Emtricitabine", + "conceptMappings":[ + + ] + }, + { + "concept":"70056AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Abacavir", + "conceptMappings":[ + + ] + } + ] }, - { - "label": "Previous ARV/HAART Drugs", - "isExpanded": "false", - "questions": [ - { - "label": "Nucleoside Reverse Transcriptase Inhibitors (NRTIS)", - "type": "obs", - "questionOptions": { - "rendering": "checkbox", - "concept": "54e7ff9b-4d93-41ba-ad0b-cb5f565785f2", - "answers": [ - { - "concept": "5424AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Other antiretroviral drug", - "conceptMappings": [] - }, - { - "concept": "86663AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Zidovudine", - "conceptMappings": [] - }, - { - "concept": "84795AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Tenofovir", - "conceptMappings": [] - }, - { - "concept": "78643AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Lamivudine", - "conceptMappings": [] - }, - { - "concept": "75628AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Emtricitabine", - "conceptMappings": [] - }, - { - "concept": "70056AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Abacavir", - "conceptMappings": [] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false", - "validators": [] - } - } - ], - "id": "nrtisDrugsUsed" - }, - { - "label": "Non-Nucleoside Reverse Transcriptase Inhibitors (NNRTIS)", - "type": "obs", - "questionOptions": { - "rendering": "checkbox", - "concept": "9064043b-5b18-4228-97ff-f0e20aaf9448", - "answers": [ - { - "concept": "159810AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Etravirine", - "conceptMappings": [] - }, - { - "concept": "80586AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Nevirapine", - "conceptMappings": [] - }, - { - "concept": "75523AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Efavirenz", - "conceptMappings": [] - }, - { - "concept": "1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Unknown", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1067" - }, - { - "type": "AMPATH", - "value": "1067" - }, - { - "type": "SNOMED CT", - "value": "CT: 261665006" - }, - { - "type": "PIH", - "value": "1067" - } - ] - }, - { - "concept": "5424AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Other antiretroviral drug", - "conceptMappings": [] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - }, - "validators": [] - } - ], - "id": "nnrtisDrugsUsed" - }, - { - "label": "Protease Inhibitors (PIS)", - "type": "obs", - "questionOptions": { - "rendering": "checkbox", - "concept": "77eed025-0f5c-4173-bf45-36e05a175aaf", - "answers": [ - { - "concept": "85160AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Tipranavir", - "conceptMappings": [] - }, - { - "concept": "83690AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Saquinavir", - "conceptMappings": [] - }, - { - "concept": "83412AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Ritonavir", - "conceptMappings": [] - }, - { - "concept": "76658AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Fosamprenavir", - "conceptMappings": [] - }, - { - "concept": "74258AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Darunavir", - "conceptMappings": [] - }, - { - "concept": "71647AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Atazanavir", - "conceptMappings": [] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - }, - "validators": [] - } - ], - "id": "proteaseInhibitors" - }, - { - "label": "Other HIV Drug Classes", - "type": "obs", - "questionOptions": { - "rendering": "checkbox", - "concept": "3509e1d9-93d0-4a6b-b5cb-90259699b01a", - "answers": [ - { - "concept": "154378AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Raltegravir", - "conceptMappings": [] - }, - { - "concept": "165085AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Dolutegravir", - "conceptMappings": [] - }, - { - "concept": "154376AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "maraviroc", - "conceptMappings": [] - }, - { - "concept": "75676AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Enfuvirtide", - "conceptMappings": [] - }, - { - "concept": "5424AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Other antiretroviral drug", - "conceptMappings": [] - }, - { - "concept": "1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Unknown", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1067" - }, - { - "type": "AMPATH", - "value": "1067" - }, - { - "type": "SNOMED CT", - "value": "CT: 261665006" - }, - { - "type": "PIH", - "value": "1067" - } - ] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - }, - "validators": [] - } - ], - "id": "otherArvDrugClasses" + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false", + "validators":[ + + ] + } + } + ], + "id":"nrtisDrugsUsed" + }, + { + "label":"Non-Nucleoside Reverse Transcriptase Inhibitors (NNRTIS)", + "type":"obs", + "questionOptions":{ + "rendering":"checkbox", + "concept":"9064043b-5b18-4228-97ff-f0e20aaf9448", + "answers":[ + { + "concept":"159810AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Etravirine", + "conceptMappings":[ + + ] + }, + { + "concept":"80586AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Nevirapine", + "conceptMappings":[ + + ] + }, + { + "concept":"75523AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Efavirenz", + "conceptMappings":[ + + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + }, + { + "type":"PIH", + "value":"1067" } - ], - "behaviours": [ - { - "intent": "*", - "hide": { - "hideWhenExpression": "isEmpty(previousUseOfArt) || isEmpty(previousUseOfPep) || isEmpty(useOfArvs) || previousUseOfArt !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || previousUseOfPep !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || useOfArvs !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - } - } - ] - } - ], - "behaviours": [ - { - "intent": "*", - "hide": { - "hideWhenExpression": "isEmpty(clientDescription) || clientDescription !== '159833AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - } - } - ] - }, - { - "label": "Treatment Supporter", - "sections": [ - { - "label": "Treatment Supporter", - "isExpanded": "true", - "questions": [ - { - "label": "Treatment Supporter Available", - "type": "obs", - "questionOptions": { - "rendering": "radio", - "concept": "0a540601-8cc4-4d18-9360-d760780f3eb1", - "answers": [ - { - "concept": "1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Yes", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1065" - }, - { - "type": "AMPATH", - "value": "1065" - }, - { - "type": "PIH", - "value": "1065" - }, - { - "type": "SNOMED CT", - "value": "CT: 373066001" - } - ] - }, - { - "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594", - "label": "No", - "conceptMappings": [] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - }, - "validators": [] - } - ], - "id": "hasTreatmentSupporter" - }, - { - "label": "Treatment Supporter Name", - "type": "obs", - "questionOptions": { - "rendering": "text", - "concept": "160638AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "isEmpty(hasTreatmentSupporter) || hasTreatmentSupporter !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - }, - "validators": [] - } - ], - "id": "treatmentSupporter" - }, - { - "label": "Treatment Supporter Phone Number", - "type": "obs", - "questionOptions": { - "rendering": "text", - "concept": "160642AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "isEmpty(hasTreatmentSupporter) || hasTreatmentSupporter !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - }, - "validators": [] - } - ], - "id": "treatmentSupporterPhoneNumber" - }, - { - "label": "Treatment Supporter Relationship", - "type": "obs", - "questionOptions": { - "rendering": "select", - "concept": "160640AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "answers": [ - { - "concept": "5622AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Other", - "conceptMappings": [ - { - "type": "PIH-Malawi", - "value": "6408" - }, - { - "type": "org.openmrs.module.mdrtb", - "value": "OTHER" - }, - { - "type": "SNOMED-MVP", - "value": "56221000105001" - }, - { - "type": "PIH", - "value": "5622" - }, - { - "type": "AMPATH", - "value": "5622" - }, - { - "type": "SNOMED-CT", - "value": "74964007" - } - ] - }, - { - "concept": "160639AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Guardian", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "394619001" - } - ] - }, - { - "concept": "973AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Grandparent", - "conceptMappings": [ - { - "type": "AMPATH", - "value": "973" - }, - { - "type": "SNOMED-CT", - "value": "38312007" - } - ] - }, - { - "concept": "5617AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Partner or spouse", - "conceptMappings": [ - { - "type": "AMPATH", - "value": "5617" - }, - { - "type": "SNOMED-CT", - "value": "127848009" - } - ] - }, - { - "concept": "1527AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Parent", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "40683002" - }, - { - "type": "PIH", - "value": "2173" - }, - { - "type": "AMPATH", - "value": "1672" - } - ] - }, - { - "concept": "972AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Sibling", - "conceptMappings": [ - { - "type": "SNOMED-CT", - "value": "375005" - }, - { - "type": "PIH", - "value": "2178" - }, - { - "type": "AMPATH", - "value": "972" - } - ] - } - ] - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "isEmpty(hasTreatmentSupporter) || hasTreatmentSupporter !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - }, - "validators": [] - } - ], - "id": "relationToTreatmentSupporter" + ] + }, + { + "concept":"5424AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Other antiretroviral drug", + "conceptMappings":[ + + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + }, + "validators":[ + + ] + } + ], + "id":"nnrtisDrugsUsed" + }, + { + "label":"Protease Inhibitors (PIS)", + "type":"obs", + "questionOptions":{ + "rendering":"checkbox", + "concept":"77eed025-0f5c-4173-bf45-36e05a175aaf", + "answers":[ + { + "concept":"85160AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Tipranavir", + "conceptMappings":[ + + ] + }, + { + "concept":"83690AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Saquinavir", + "conceptMappings":[ + + ] + }, + { + "concept":"83412AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Ritonavir", + "conceptMappings":[ + + ] + }, + { + "concept":"76658AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Fosamprenavir", + "conceptMappings":[ + + ] + }, + { + "concept":"74258AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Darunavir", + "conceptMappings":[ + + ] + }, + { + "concept":"71647AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Atazanavir", + "conceptMappings":[ + + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + }, + "validators":[ + + ] + } + ], + "id":"proteaseInhibitors" + }, + { + "label":"Other HIV Drug Classes", + "type":"obs", + "questionOptions":{ + "rendering":"checkbox", + "concept":"3509e1d9-93d0-4a6b-b5cb-90259699b01a", + "answers":[ + { + "concept":"154378AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Raltegravir", + "conceptMappings":[ + + ] + }, + { + "concept":"165085AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Dolutegravir", + "conceptMappings":[ + + ] + }, + { + "concept":"154376AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"maraviroc", + "conceptMappings":[ + + ] + }, + { + "concept":"75676AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Enfuvirtide", + "conceptMappings":[ + + ] + }, + { + "concept":"5424AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Other antiretroviral drug", + "conceptMappings":[ + + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + }, + { + "type":"PIH", + "value":"1067" } + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + }, + "validators":[ + ] - } + } + ], + "id":"otherArvDrugClasses" + } ], - "behaviours": [ - { - "intent": "*", - "hide": { - "hideWhenExpression": "isEmpty(clientDescription) || clientDescription !== '159833AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - } - } - ] - }, - { - "label": "Re-enrollment", - "sections": [ - { - "label": "Re-enrollment Details", - "isExpanded": "true", - "questions": [ - { - "label": "Date of Re-enrolment", - "type": "obs", - "questionOptions": { - "rendering": "date", - "concept": "20efadf9-86d3-4498-b3ab-7da4dad9c429" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "false", - "hide": { - "hideWhenExpression": "false" - }, - "validators": [] - } - ], - "id": "Reenrolment" - }, - { - "label": "Reason For Re-enrolment", - "type": "obs", - "questionOptions": { - "rendering": "textarea", - "concept": "14ae2dc9-5964-425a-87e8-9ca525cf055e", - "rows": "" - }, - "behaviours": [ - { - "intent": "*", - "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "false" - }, - "validators": [] - } - ], - "id": "ReasonReenrolment" + "behaviours":[ + { + "intent":"*", + "hide":{ + "hideWhenExpression":"isEmpty(previousUseOfArt) || isEmpty(previousUseOfPep) || isEmpty(useOfArvs) || previousUseOfArt !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || previousUseOfPep !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || useOfArvs !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } + ] + } + ], + "behaviours":[ + { + "intent":"*", + "hide":{ + "hideWhenExpression":"isEmpty(clientDescription) || clientDescription !== '159833AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } + ] + }, + { + "label":"Treatment Supporter", + "sections":[ + { + "label":"Treatment Supporter", + "isExpanded":"true", + "questions":[ + { + "label":"Treatment Supporter Available", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"0a540601-8cc4-4d18-9360-d760780f3eb1", + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" } + ] + }, + { + "concept":"488b58ff-64f5-4f8a-8979-fa79940b1594", + "label":"No", + "conceptMappings":[ + + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + }, + "validators":[ + ] - } - ], - "behaviours": [ - { - "intent": "*", - "hide": { - "hideWhenExpression": "isEmpty(clientDescription) || clientDescription !== '159833AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" - } - } - ] - } + } + ], + "id":"hasTreatmentSupporter" + }, + { + "label":"Treatment Supporter Name", + "type":"obs", + "questionOptions":{ + "rendering":"text", + "concept":"160638AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"isEmpty(hasTreatmentSupporter) || hasTreatmentSupporter !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + }, + "validators":[ + + ] + } + ], + "id":"treatmentSupporter" + }, + { + "label":"Treatment Supporter Phone Number", + "type":"obs", + "questionOptions":{ + "rendering":"text", + "concept":"160642AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"isEmpty(hasTreatmentSupporter) || hasTreatmentSupporter !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + }, + "validators":[ + + ] + } + ], + "id":"treatmentSupporterPhoneNumber" + }, + { + "label":"Treatment Supporter Relationship", + "type":"obs", + "questionOptions":{ + "rendering":"select", + "concept":"160640AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "answers":[ + { + "concept":"5622AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Other", + "conceptMappings":[ + { + "type":"PIH-Malawi", + "value":"6408" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"OTHER" + }, + { + "type":"SNOMED-MVP", + "value":"56221000105001" + }, + { + "type":"PIH", + "value":"5622" + }, + { + "type":"AMPATH", + "value":"5622" + }, + { + "type":"SNOMED-CT", + "value":"74964007" + } + ] + }, + { + "concept":"160639AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Guardian", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"394619001" + } + ] + }, + { + "concept":"973AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Grandparent", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"973" + }, + { + "type":"SNOMED-CT", + "value":"38312007" + } + ] + }, + { + "concept":"5617AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Partner or spouse", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"5617" + }, + { + "type":"SNOMED-CT", + "value":"127848009" + } + ] + }, + { + "concept":"1527AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Parent", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"40683002" + }, + { + "type":"PIH", + "value":"2173" + }, + { + "type":"AMPATH", + "value":"1672" + } + ] + }, + { + "concept":"972AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Sibling", + "conceptMappings":[ + { + "type":"SNOMED-CT", + "value":"375005" + }, + { + "type":"PIH", + "value":"2178" + }, + { + "type":"AMPATH", + "value":"972" + } + ] + } + ] + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"isEmpty(hasTreatmentSupporter) || hasTreatmentSupporter !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + }, + "validators":[ + + ] + } + ], + "id":"relationToTreatmentSupporter" + } + ] + } + ], + "behaviours":[ + { + "intent":"*", + "hide":{ + "hideWhenExpression":"isEmpty(clientDescription) || clientDescription !== '159833AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } + ] + }, + { + "label":"Re-enrollment", + "sections":[ + { + "label":"Re-enrollment Details", + "isExpanded":"true", + "questions":[ + { + "label":"Date of Re-enrolment", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"20efadf9-86d3-4498-b3ab-7da4dad9c429" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"false", + "hide":{ + "hideWhenExpression":"false" + }, + "validators":[ + + ] + } + ], + "id":"Reenrolment" + }, + { + "label":"Reason For Re-enrolment", + "type":"obs", + "questionOptions":{ + "rendering":"textarea", + "concept":"14ae2dc9-5964-425a-87e8-9ca525cf055e", + "rows":"" + }, + "behaviours":[ + { + "intent":"*", + "required":"true", + "unspecified":"true", + "hide":{ + "hideWhenExpression":"false" + }, + "validators":[ + + ] + } + ], + "id":"ReasonReenrolment" + } + ] + } + ], + "behaviours":[ + { + "intent":"*", + "hide":{ + "hideWhenExpression":"isEmpty(clientDescription) || clientDescription !== '159833AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } + ] + } + ], + "availableIntents":[ + { + "intent":"*", + "display":"Service Enrolment Form" + } ], - "availableIntents": [ - { - "intent": "*", - "display": "Service Enrolment Form" - } - ], - "processor": "EncounterFormProcessor", - "uuid": "xxxx", - "referencedForms": [], - "encounterType": "7e54cd64-f9c3-11eb-8e6a-57478ce139b0", - "allowUnspecifiedAll": true -} + "processor":"EncounterFormProcessor", + "uuid":"xxxx", + "referencedForms":[], + "encounterType":"7e54cd64-f9c3-11eb-8e6a-57478ce139b0", + "allowUnspecifiedAll":true + } \ No newline at end of file diff --git a/src/pages/program-management/tabs/hiv-enrolment-tab.component.tsx b/src/pages/program-management/tabs/hiv-enrolment-tab.component.tsx index 4f46fc0b2..246c36a26 100644 --- a/src/pages/program-management/tabs/hiv-enrolment-tab.component.tsx +++ b/src/pages/program-management/tabs/hiv-enrolment-tab.component.tsx @@ -3,6 +3,7 @@ import { useTranslation } from 'react-i18next'; import EmptyState from '../../../components/empty-state/empty-state.component'; import EncounterList, { EncounterListColumn, + findObs, getObsFromEncounter, } from '../../../components/encounter-list/encounter-list.component'; import { @@ -13,6 +14,7 @@ import { entryPointConcept, patientTypeEnrollmentConcept, re_enrolmentDateConcept, + otherEntryPoint, } from '../../../constants'; interface HIVEnrolmentTabListProps { @@ -47,6 +49,19 @@ const columns: EncounterListColumn[] = [ key: 'entryPoint', header: 'Entry Point', getValue: encounter => { + const obs = findObs(encounter, entryPointConcept); + if (typeof obs !== undefined && obs) { + if (typeof obs.value === 'object') { + if (obs !== undefined) { + const EntryPoint = + obs.value.names?.find(conceptName => conceptName.conceptNameType === 'SHORT')?.name || + obs.value.name.name; + if (EntryPoint === 'Other non-coded') { + return getObsFromEncounter(encounter, otherEntryPoint); + } + } + } + } return getObsFromEncounter(encounter, entryPointConcept); }, }, From d1c22cbe81b6603d600dc00b884c06048b774da6 Mon Sep 17 00:00:00 2001 From: AJAL ODORA JONATHAN <43242517+ODORA0@users.noreply.github.com> Date: Mon, 21 Mar 2022 17:05:15 +0300 Subject: [PATCH 08/23] OHRI-746 HTS Form (Classic) enabled to save in OHRI --- src/packages/hiv/forms/hts/2.0.json | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/packages/hiv/forms/hts/2.0.json b/src/packages/hiv/forms/hts/2.0.json index d02da00bf..c7dd4fe62 100644 --- a/src/packages/hiv/forms/hts/2.0.json +++ b/src/packages/hiv/forms/hts/2.0.json @@ -2717,10 +2717,11 @@ "answers": [ { "label": "Yes", - "concept": "1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + "concept": "cf82933b-3f3f-45e7-a5ab-5d31aaee3da3" }, { - "label": "No" + "label": "No", + "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594" } ] }, From b7214d5a8202265f12d29cf8043463d814b2d534 Mon Sep 17 00:00:00 2001 From: Jovan Ssebaggala Date: Tue, 22 Mar 2022 10:42:20 +0300 Subject: [PATCH 09/23] OHRI-747 fix recency and post-test concepts --- src/packages/hiv/forms/hts-who/1.0.json | 68 ++++++++++++++++++++++--- 1 file changed, 62 insertions(+), 6 deletions(-) diff --git a/src/packages/hiv/forms/hts-who/1.0.json b/src/packages/hiv/forms/hts-who/1.0.json index 15f7d3c97..9077375db 100644 --- a/src/packages/hiv/forms/hts-who/1.0.json +++ b/src/packages/hiv/forms/hts-who/1.0.json @@ -2467,10 +2467,11 @@ "answers": [ { "label": "Yes", - "concept": "1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + "concept": "cf82933b-3f3f-45e7-a5ab-5d31aaee3da3" }, { - "label": "No" + "label": "No", + "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594" } ] }, @@ -2630,7 +2631,7 @@ ], "answers": [ { - "concept": "cf82933b-3f3f-45e7-a5ab-5d31aaee3da3", + "concept": "1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", "label": "Yes", "conceptMappings": [ { @@ -2645,16 +2646,71 @@ "type": "PIH", "value": "1065" }, + { + "type": "SNOMED-CT", + "value": "373066001" + }, { "type": "SNOMED CT", - "value": "CT: 373066001" + "value": "373066001" + }, + { + "type": "PIH-Malawi", + "value": "1065" } ] }, { - "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594", + "concept": "1066AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", "label": "No", - "conceptMappings": [] + "conceptMappings": [ + { + "type": "CIEL", + "value": "1066" + }, + { + "type": "AMPATH", + "value": "1066" + }, + { + "type": "PIH", + "value": "1066" + }, + { + "type": "SNOMED-CT", + "value": "373067005" + }, + { + "type": "PIH-Malawi", + "value": "1066" + } + ] + }, + { + "concept": "1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Unknown", + "conceptMappings": [ + { + "type": "CIEL", + "value": "1067" + }, + { + "type": "AMPATH", + "value": "1067" + }, + { + "type": "PIH", + "value": "1067" + }, + { + "type": "SNOMED-CT", + "value": "261665006" + }, + { + "type": "SNOMED CT", + "value": "261665006" + } + ] } ] }, From e457fb6a7dd5f7095c1eb44aca2d2ab67cf6267f Mon Sep 17 00:00:00 2001 From: Jovan Ssebaggala Date: Tue, 22 Mar 2022 18:13:19 +0300 Subject: [PATCH 10/23] OHRI-736 fix ART therapy display list --- .../encounter-list.component.tsx | 29 +++++++++++++++++-- src/constants.ts | 2 ++ .../tabs/art-therapy-tab.component.tsx | 5 +++- src/utils/art-concepts.ts | 7 +++++ 4 files changed, 40 insertions(+), 3 deletions(-) create mode 100644 src/utils/art-concepts.ts diff --git a/src/components/encounter-list/encounter-list.component.tsx b/src/components/encounter-list/encounter-list.component.tsx index be375e955..fd571bf6e 100644 --- a/src/components/encounter-list/encounter-list.component.tsx +++ b/src/components/encounter-list/encounter-list.component.tsx @@ -8,7 +8,13 @@ import { OHRIFormLauncherWithIntent } from '../ohri-form-launcher/ohri-form-laun import styles from './encounter-list.scss'; import OTable from '../data-table/o-table.component'; import { Button, Link, OverflowMenu, OverflowMenuItem, Pagination } from 'carbon-components-react'; -import { encounterRepresentation, stopReasonUUID, substituteReasonUUID, switchReasonUUID } from '../../constants'; +import { + encounterRepresentation, + stopReasonUUID, + substituteReasonUUID, + switchReasonUUID, + restartReasonUUID, +} from '../../constants'; import moment from 'moment'; import { Add16 } from '@carbon/icons-react'; import { @@ -17,6 +23,7 @@ import { launchFormInViewMode, launchFormWithCustomTitle, } from '../../utils/ohri-forms-commons'; +import { artConcepts } from '../../utils/art-concepts'; export interface EncounterListColumn { key: string; @@ -30,6 +37,7 @@ export interface ARTDateConcepts { switchDateUUID: string; substitutionDateUUID: string; artStopDateUUID: string; + dateRestartedUUID: string; } export interface EncounterListProps { @@ -68,6 +76,10 @@ function obsArrayDateComparator(left, right) { return formatDateTime(right.obsDatetime) - formatDateTime(left.obsDatetime); } +export function getTherapyPlan(uuid: string) { + return artConcepts.get(uuid); +} + export function findObs(encounter, obsConcept): Record { const allObs = encounter?.obs.filter(observation => observation.concept.uuid === obsConcept); return allObs?.length == 1 ? allObs[0] : allObs?.sort(obsArrayDateComparator)[0]; @@ -80,6 +92,7 @@ export function getObsFromEncounters(encounters, obsConcept) { export function getObsFromEncounter(encounter, obsConcept, isDate?: Boolean, isTrueFalseConcept?: Boolean) { const obs = findObs(encounter, obsConcept); + if (isTrueFalseConcept) { return obs ? 'Yes' : 'No'; } @@ -90,6 +103,9 @@ export function getObsFromEncounter(encounter, obsConcept, isDate?: Boolean, isT return moment(obs.value).format('DD-MMM-YYYY'); } if (typeof obs.value === 'object') { + if (obsConcept === '7557d77c-172b-4673-9335-67a38657dd01') { + return getTherapyPlan(obs.value.uuid); + } return obs.value.names?.find(conceptName => conceptName.conceptNameType === 'SHORT')?.name || obs.value.name.name; } return obs.value; @@ -100,11 +116,13 @@ export function getLatestARTDateConcept(encounter, dateConcepts: ARTDateConcepts let artSubstitutionDate = findObs(encounter, dateConcepts.substitutionDateUUID); let artSwitchDate = findObs(encounter, dateConcepts.switchDateUUID); let artStopDate = findObs(encounter, dateConcepts.artStopDateUUID); + let artRestartDate = findObs(encounter, dateConcepts.dateRestartedUUID); artStartDate = artStartDate ? artStartDate.value : null; artSubstitutionDate = artSubstitutionDate ? artSubstitutionDate.value : null; artSwitchDate = artSwitchDate ? artSwitchDate.value : null; artStopDate = artStopDate ? artStopDate.value : null; + artRestartDate = artRestartDate ? artRestartDate.value : null; let latestDateConcept: string = dateConcepts.artTherapyDateTime_UUID; let latestDate = artStartDate; @@ -120,6 +138,10 @@ export function getLatestARTDateConcept(encounter, dateConcepts: ARTDateConcepts latestDate = artStopDate; latestDateConcept = dateConcepts.artStopDateUUID; } + if (artRestartDate > latestDate) { + latestDate = artRestartDate; + latestDateConcept = dateConcepts.dateRestartedUUID; + } return latestDateConcept; } @@ -137,10 +159,13 @@ export function getARTReasonConcept(encounter, dateConcepts: ARTDateConcepts): s case dateConcepts.switchDateUUID: artReaseonConcept = switchReasonUUID; break; + case dateConcepts.dateRestartedUUID: + artReaseonConcept = restartReasonUUID; + break; default: artReaseonConcept = ''; } - + console.log(latestDateConcept + ' - ' + artReaseonConcept); return artReaseonConcept; } diff --git a/src/constants.ts b/src/constants.ts index afb552ade..d401fb154 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -145,9 +145,11 @@ export const therapyPlanConcept = '7557d77c-172b-4673-9335-67a38657dd01'; export const artStopDateUUID = '162572AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const switchDateUUID = '164516AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const substitutionDateUUID = '164431AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; +export const dateRestartedUUID = '160738AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const switchReasonUUID = '160568AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const substituteReasonUUID = '160562AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const stopReasonUUID = '163513AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; +export const restartReasonUUID = '161011AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; // HIV Lab Results export const hivLabResultsEncounterType_UUID = ' 15272be5-ae9c-4278-a303-4b8907eae73b'; diff --git a/src/pages/program-management/tabs/art-therapy-tab.component.tsx b/src/pages/program-management/tabs/art-therapy-tab.component.tsx index b01e0677e..5df0b6a63 100644 --- a/src/pages/program-management/tabs/art-therapy-tab.component.tsx +++ b/src/pages/program-management/tabs/art-therapy-tab.component.tsx @@ -20,6 +20,7 @@ import { artStopDateUUID, substitutionDateUUID, switchDateUUID, + dateRestartedUUID, } from '../../../constants'; interface ArtTherapyTabListProps { @@ -31,7 +32,7 @@ const ARTDates: string[] = [artTherapyDateTime_UUID, switchDateUUID, substitutio const columns: EncounterListColumn[] = [ { key: 'initiationDate', - header: 'Date(ART Start, Stopped, Switched, Change)', + header: 'Date(ART Start, Stopped, Switched, Changed, Restarted)', getValue: encounter => { return getObsFromEncounter( encounter, @@ -40,6 +41,7 @@ const columns: EncounterListColumn[] = [ switchDateUUID, substitutionDateUUID, artStopDateUUID, + dateRestartedUUID, }), true, ); @@ -77,6 +79,7 @@ const columns: EncounterListColumn[] = [ switchDateUUID, substitutionDateUUID, artStopDateUUID, + dateRestartedUUID, }), ); }, diff --git a/src/utils/art-concepts.ts b/src/utils/art-concepts.ts new file mode 100644 index 000000000..b659e33b1 --- /dev/null +++ b/src/utils/art-concepts.ts @@ -0,0 +1,7 @@ +export let artConcepts = new Map([ + ['1256AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Start ART'], + ['1258AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Substitute ART Regimen'], + ['1259AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Switch ART Regimen Line'], + ['1260AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Stop ART'], + ['3e69cb60-2943-410f-83d4-b359ae83fefd', 'Restart ART therapy'], +]); From d0d5a13517d549eb5f05e97f6e092e8b0be83895 Mon Sep 17 00:00:00 2001 From: Jovan Ssebaggala Date: Tue, 22 Mar 2022 18:14:49 +0300 Subject: [PATCH 11/23] OHRI-736 fix ART therapy display list clean up --- src/components/encounter-list/encounter-list.component.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/src/components/encounter-list/encounter-list.component.tsx b/src/components/encounter-list/encounter-list.component.tsx index fd571bf6e..f31214c0f 100644 --- a/src/components/encounter-list/encounter-list.component.tsx +++ b/src/components/encounter-list/encounter-list.component.tsx @@ -165,7 +165,6 @@ export function getARTReasonConcept(encounter, dateConcepts: ARTDateConcepts): s default: artReaseonConcept = ''; } - console.log(latestDateConcept + ' - ' + artReaseonConcept); return artReaseonConcept; } From 44d62c0d427e70450e62b2dbfb553cd605c90164 Mon Sep 17 00:00:00 2001 From: Jovan Ssebaggala Date: Wed, 23 Mar 2022 12:19:13 +0300 Subject: [PATCH 12/23] OHRI-736 Code refactoring --- .../encounter-list/encounter-list.component.tsx | 2 +- .../program-management/tabs/art-therapy-tab.component.tsx | 8 +++++++- src/utils/art-concepts.ts | 7 ------- 3 files changed, 8 insertions(+), 9 deletions(-) delete mode 100644 src/utils/art-concepts.ts diff --git a/src/components/encounter-list/encounter-list.component.tsx b/src/components/encounter-list/encounter-list.component.tsx index f31214c0f..742f96c1f 100644 --- a/src/components/encounter-list/encounter-list.component.tsx +++ b/src/components/encounter-list/encounter-list.component.tsx @@ -23,7 +23,7 @@ import { launchFormInViewMode, launchFormWithCustomTitle, } from '../../utils/ohri-forms-commons'; -import { artConcepts } from '../../utils/art-concepts'; +import { artConcepts } from '../../pages/program-management/tabs/art-therapy-tab.component'; export interface EncounterListColumn { key: string; diff --git a/src/pages/program-management/tabs/art-therapy-tab.component.tsx b/src/pages/program-management/tabs/art-therapy-tab.component.tsx index 5df0b6a63..2f48ac184 100644 --- a/src/pages/program-management/tabs/art-therapy-tab.component.tsx +++ b/src/pages/program-management/tabs/art-therapy-tab.component.tsx @@ -27,7 +27,13 @@ interface ArtTherapyTabListProps { patientUuid: string; } -const ARTDates: string[] = [artTherapyDateTime_UUID, switchDateUUID, substitutionDateUUID, artStopDateUUID]; +export const artConcepts = new Map([ + ['1256AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Start ART'], + ['1258AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Substitute ART Regimen'], + ['1259AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Switch ART Regimen Line'], + ['1260AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Stop ART'], + ['3e69cb60-2943-410f-83d4-b359ae83fefd', 'Restart ART therapy'], +]); const columns: EncounterListColumn[] = [ { diff --git a/src/utils/art-concepts.ts b/src/utils/art-concepts.ts deleted file mode 100644 index b659e33b1..000000000 --- a/src/utils/art-concepts.ts +++ /dev/null @@ -1,7 +0,0 @@ -export let artConcepts = new Map([ - ['1256AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Start ART'], - ['1258AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Substitute ART Regimen'], - ['1259AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Switch ART Regimen Line'], - ['1260AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Stop ART'], - ['3e69cb60-2943-410f-83d4-b359ae83fefd', 'Restart ART therapy'], -]); From d352f6c98a81f2fe861d82e40ffd44a7fc402a54 Mon Sep 17 00:00:00 2001 From: Jovan Ssebaggala Date: Wed, 23 Mar 2022 14:25:37 +0300 Subject: [PATCH 13/23] OHRI-736 More code refactoring --- .../encounter-list/encounter-list.component.tsx | 8 -------- .../program-management/tabs/art-therapy-tab.component.tsx | 6 ++++-- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/src/components/encounter-list/encounter-list.component.tsx b/src/components/encounter-list/encounter-list.component.tsx index 742f96c1f..791dd4a89 100644 --- a/src/components/encounter-list/encounter-list.component.tsx +++ b/src/components/encounter-list/encounter-list.component.tsx @@ -23,7 +23,6 @@ import { launchFormInViewMode, launchFormWithCustomTitle, } from '../../utils/ohri-forms-commons'; -import { artConcepts } from '../../pages/program-management/tabs/art-therapy-tab.component'; export interface EncounterListColumn { key: string; @@ -76,10 +75,6 @@ function obsArrayDateComparator(left, right) { return formatDateTime(right.obsDatetime) - formatDateTime(left.obsDatetime); } -export function getTherapyPlan(uuid: string) { - return artConcepts.get(uuid); -} - export function findObs(encounter, obsConcept): Record { const allObs = encounter?.obs.filter(observation => observation.concept.uuid === obsConcept); return allObs?.length == 1 ? allObs[0] : allObs?.sort(obsArrayDateComparator)[0]; @@ -103,9 +98,6 @@ export function getObsFromEncounter(encounter, obsConcept, isDate?: Boolean, isT return moment(obs.value).format('DD-MMM-YYYY'); } if (typeof obs.value === 'object') { - if (obsConcept === '7557d77c-172b-4673-9335-67a38657dd01') { - return getTherapyPlan(obs.value.uuid); - } return obs.value.names?.find(conceptName => conceptName.conceptNameType === 'SHORT')?.name || obs.value.name.name; } return obs.value; diff --git a/src/pages/program-management/tabs/art-therapy-tab.component.tsx b/src/pages/program-management/tabs/art-therapy-tab.component.tsx index 2f48ac184..d672c512f 100644 --- a/src/pages/program-management/tabs/art-therapy-tab.component.tsx +++ b/src/pages/program-management/tabs/art-therapy-tab.component.tsx @@ -10,6 +10,7 @@ import EncounterList, { getEncounterValues, getLatestARTDateConcept, getARTReasonConcept, + findObs, } from '../../../components/encounter-list/encounter-list.component'; import { artTherapyDateTime_UUID, @@ -27,7 +28,7 @@ interface ArtTherapyTabListProps { patientUuid: string; } -export const artConcepts = new Map([ +const artConcepts = new Map([ ['1256AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Start ART'], ['1258AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Substitute ART Regimen'], ['1259AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA', 'Switch ART Regimen Line'], @@ -57,7 +58,8 @@ const columns: EncounterListColumn[] = [ key: 'therapyPlan', header: 'Therapy Plan', getValue: encounter => { - return getObsFromEncounter(encounter, therapyPlanConcept); + const therapyPlanObs = findObs(encounter, therapyPlanConcept); + return therapyPlanObs ? artConcepts.get(therapyPlanObs.value.uuid) : '--'; }, }, { From f6e82a0c1bad053235a4a6047d9cfac45e5e57de Mon Sep 17 00:00:00 2001 From: Jovan Ssebaggala Date: Wed, 23 Mar 2022 16:50:09 +0300 Subject: [PATCH 14/23] OHRI-729 Service Delivery tab contents added --- .../program-management-summary.component.tsx | 2 +- .../tabs/service-delivery-tab.component.tsx | 79 +++++++++++++++++-- 2 files changed, 75 insertions(+), 6 deletions(-) diff --git a/src/pages/program-management/program-management-summary.component.tsx b/src/pages/program-management/program-management-summary.component.tsx index 99f5dd06a..16e17fcd8 100644 --- a/src/pages/program-management/program-management-summary.component.tsx +++ b/src/pages/program-management/program-management-summary.component.tsx @@ -17,7 +17,7 @@ const ProgramManagementSummary: React.FC = ({ patientUuid }) - + diff --git a/src/pages/program-management/tabs/service-delivery-tab.component.tsx b/src/pages/program-management/tabs/service-delivery-tab.component.tsx index fa322258b..414750828 100644 --- a/src/pages/program-management/tabs/service-delivery-tab.component.tsx +++ b/src/pages/program-management/tabs/service-delivery-tab.component.tsx @@ -1,21 +1,90 @@ import React, { useEffect, useState } from 'react'; import { useTranslation } from 'react-i18next'; import EmptyState from '../../../components/empty-state/empty-state.component'; +import EncounterList, { EncounterListColumn } from '../../../components/encounter-list/encounter-list.component'; interface ServiceDeliveryTabListProps { patientUuid: string; } +const columnsLab: EncounterListColumn[] = [ + { + key: 'mostRecentVLResults', + header: 'Most recent VL results ', + getValue: encounter => { + return null; + }, + }, + { + key: 'vlDate', + header: 'Date VL done', + getValue: encounter => { + return null; + }, + }, + { + key: 'currentRegimenDuration', + header: 'Duration of current Regimen', + getValue: encounter => { + return null; + }, + }, + { + key: 'adherenceLevel', + header: 'Good Adherence in the Last 6 months', + getValue: encounter => { + return null; + }, + }, + { + key: 'dsdModel', + header: 'DSD Model', + getValue: encounter => { + return null; + }, + }, + + { + key: 'actions', + header: 'Actions', + getValue: encounter => { + const baseActions = [ + { + form: { name: '', package: '' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'View Details', + mode: 'view', + }, + { + form: { name: '', package: '' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'Edit', + mode: 'edit', + }, + ]; + return baseActions; + }, + }, +]; + const ServiceDeliveryTabList: React.FC = ({ patientUuid }) => { const { t } = useTranslation(); - const headerTitle = t('serviceDelivery', 'Service Delivery'); - const displayText = t('serviceDelivery', 'Service Delivery'); + const headerTitle = t('serviceDelivery', 'Service Delivery Model'); + const displayText = t('serviceDelivery', 'Service Delivery Model'); return ( - <> - - + ); }; From 990fdf29ad600998d4af1eb6217c0c0359213bc6 Mon Sep 17 00:00:00 2001 From: Samuel Male Date: Wed, 23 Mar 2022 23:27:55 +0300 Subject: [PATCH 15/23] OHRI-721: Support for skip logic at the section level --- .../encounter/ohri-encounter-form.tsx | 18 ++++++++++ src/forms/components/page/ohri-form-page.tsx | 33 ++++++++++--------- src/forms/types.ts | 1 + src/forms/utils/expression-runner.ts | 1 + 4 files changed, 38 insertions(+), 15 deletions(-) diff --git a/src/forms/components/encounter/ohri-encounter-form.tsx b/src/forms/components/encounter/ohri-encounter-form.tsx index 0af81f871..fcfc98048 100644 --- a/src/forms/components/encounter/ohri-encounter-form.tsx +++ b/src/forms/components/encounter/ohri-encounter-form.tsx @@ -196,6 +196,13 @@ export const OHRIEncounterForm: React.FC = ({ } else { page.isHidden = false; } + page.sections.forEach(section => { + if (section.hide) { + evalHide({ value: section, type: 'section' }, allFormFields, tempInitVals); + } else { + section.isHidden = false; + } + }); }); setForm(form); setFormInitialValues(tempInitVals); @@ -418,6 +425,17 @@ export const OHRIEncounterForm: React.FC = ({ setFields(fields_temp); }); } + if (field.sectionDependants) { + field.sectionDependants.forEach(dependant => { + for (let i = 0; i < form.pages.length; i++) { + const section = form.pages[i].sections.find((section, _sectionIndex) => section.label == dependant); + if (section) { + evalHide({ value: section, type: 'section' }, fields, { ...values, [fieldName]: value }); + break; + } + } + }); + } if (field.pageDependants) { field.pageDependants?.forEach(dep => { const dependant = form.pages.find(f => f.label == dep); diff --git a/src/forms/components/page/ohri-form-page.tsx b/src/forms/components/page/ohri-form-page.tsx index d4a37dd43..49bdb73f7 100644 --- a/src/forms/components/page/ohri-form-page.tsx +++ b/src/forms/components/page/ohri-form-page.tsx @@ -3,6 +3,7 @@ import styles from './_page.scss'; import OHRIFormSection from '../section/ohri-form-section.component'; import { Waypoint } from 'react-waypoint'; import { Accordion, AccordionItem } from 'carbon-components-react'; +import { isTrue } from '../../utils/boolean-utils'; function OHRIFormPage({ page, onFieldChange, setSelectedPage, isCollapsed }) { let newLabel = page.label.replace(/\s/g, ''); @@ -19,21 +20,23 @@ function OHRIFormPage({ page, onFieldChange, setSelectedPage, isCollapsed }) { {/*

All fields are required unless marked optional

*/} - {page.sections.map((sec, index) => { - return ( - -
- 1} - onFieldChange={onFieldChange} - sectionTitle={sec.label} - key={index} - /> -
-
- ); - })} + {page.sections + .filter(sec => !isTrue(sec.isHidden)) + .map((sec, index) => { + return ( + +
+ 1} + onFieldChange={onFieldChange} + sectionTitle={sec.label} + key={index} + /> +
+
+ ); + })}
diff --git a/src/forms/types.ts b/src/forms/types.ts index b2b60783b..7c539a0f2 100644 --- a/src/forms/types.ts +++ b/src/forms/types.ts @@ -105,6 +105,7 @@ export interface OHRIFormFieldProps { handler: SubmissionHandler; } export interface OHRIFormSection { + hide?: HideProps; label: string; isExpanded: string; isHidden?: boolean; diff --git a/src/forms/utils/expression-runner.ts b/src/forms/utils/expression-runner.ts index e94f250c3..8b3f1889f 100644 --- a/src/forms/utils/expression-runner.ts +++ b/src/forms/utils/expression-runner.ts @@ -105,6 +105,7 @@ function registerDependency(node: FormNode, determinant: OHRIFormField) { determinant.sectionDependants = new Set(); } determinant.sectionDependants.add(node.value.label); + break; default: if (!determinant.fieldDependants) { determinant.fieldDependants = new Set(); From e25cc380b799a66d806f68a45d1922b9232f89d8 Mon Sep 17 00:00:00 2001 From: Jovan Ssebaggala Date: Wed, 23 Mar 2022 23:32:53 +0300 Subject: [PATCH 16/23] OHRI-729 ART therapy code refactoring --- .../encounter-list.component.tsx | 73 +------------------ .../tabs/art-therapy-tab.component.tsx | 71 +++++++++++++++++- 2 files changed, 70 insertions(+), 74 deletions(-) diff --git a/src/components/encounter-list/encounter-list.component.tsx b/src/components/encounter-list/encounter-list.component.tsx index 791dd4a89..467cfe3cb 100644 --- a/src/components/encounter-list/encounter-list.component.tsx +++ b/src/components/encounter-list/encounter-list.component.tsx @@ -8,13 +8,7 @@ import { OHRIFormLauncherWithIntent } from '../ohri-form-launcher/ohri-form-laun import styles from './encounter-list.scss'; import OTable from '../data-table/o-table.component'; import { Button, Link, OverflowMenu, OverflowMenuItem, Pagination } from 'carbon-components-react'; -import { - encounterRepresentation, - stopReasonUUID, - substituteReasonUUID, - switchReasonUUID, - restartReasonUUID, -} from '../../constants'; +import { encounterRepresentation } from '../../constants'; import moment from 'moment'; import { Add16 } from '@carbon/icons-react'; import { @@ -30,14 +24,6 @@ export interface EncounterListColumn { getValue: (encounter: any) => string; link?: any; } -// -export interface ARTDateConcepts { - artTherapyDateTime_UUID: string; - switchDateUUID: string; - substitutionDateUUID: string; - artStopDateUUID: string; - dateRestartedUUID: string; -} export interface EncounterListProps { patientUuid: string; @@ -103,63 +89,6 @@ export function getObsFromEncounter(encounter, obsConcept, isDate?: Boolean, isT return obs.value; } -export function getLatestARTDateConcept(encounter, dateConcepts: ARTDateConcepts): string { - let artStartDate = findObs(encounter, dateConcepts.artTherapyDateTime_UUID); - let artSubstitutionDate = findObs(encounter, dateConcepts.substitutionDateUUID); - let artSwitchDate = findObs(encounter, dateConcepts.switchDateUUID); - let artStopDate = findObs(encounter, dateConcepts.artStopDateUUID); - let artRestartDate = findObs(encounter, dateConcepts.dateRestartedUUID); - - artStartDate = artStartDate ? artStartDate.value : null; - artSubstitutionDate = artSubstitutionDate ? artSubstitutionDate.value : null; - artSwitchDate = artSwitchDate ? artSwitchDate.value : null; - artStopDate = artStopDate ? artStopDate.value : null; - artRestartDate = artRestartDate ? artRestartDate.value : null; - - let latestDateConcept: string = dateConcepts.artTherapyDateTime_UUID; - let latestDate = artStartDate; - if (artSubstitutionDate > latestDate) { - latestDateConcept = dateConcepts.substitutionDateUUID; - latestDate = artSubstitutionDate; - } - if (artSwitchDate > latestDate) { - latestDate = artSwitchDate; - latestDateConcept = dateConcepts.switchDateUUID; - } - if (artStopDate > latestDate) { - latestDate = artStopDate; - latestDateConcept = dateConcepts.artStopDateUUID; - } - if (artRestartDate > latestDate) { - latestDate = artRestartDate; - latestDateConcept = dateConcepts.dateRestartedUUID; - } - - return latestDateConcept; -} - -export function getARTReasonConcept(encounter, dateConcepts: ARTDateConcepts): string { - const latestDateConcept: string = getLatestARTDateConcept(encounter, dateConcepts); - let artReaseonConcept = ''; - switch (latestDateConcept) { - case dateConcepts.artStopDateUUID: - artReaseonConcept = stopReasonUUID; - break; - case dateConcepts.substitutionDateUUID: - artReaseonConcept = substituteReasonUUID; - break; - case dateConcepts.switchDateUUID: - artReaseonConcept = switchReasonUUID; - break; - case dateConcepts.dateRestartedUUID: - artReaseonConcept = restartReasonUUID; - break; - default: - artReaseonConcept = ''; - } - return artReaseonConcept; -} - const EncounterList: React.FC = ({ patientUuid, encounterUuid, diff --git a/src/pages/program-management/tabs/art-therapy-tab.component.tsx b/src/pages/program-management/tabs/art-therapy-tab.component.tsx index d672c512f..43051981f 100644 --- a/src/pages/program-management/tabs/art-therapy-tab.component.tsx +++ b/src/pages/program-management/tabs/art-therapy-tab.component.tsx @@ -8,8 +8,6 @@ import EncounterList, { EncounterListColumn, getObsFromEncounter, getEncounterValues, - getLatestARTDateConcept, - getARTReasonConcept, findObs, } from '../../../components/encounter-list/encounter-list.component'; import { @@ -22,6 +20,10 @@ import { substitutionDateUUID, switchDateUUID, dateRestartedUUID, + restartReasonUUID, + stopReasonUUID, + substituteReasonUUID, + switchReasonUUID, } from '../../../constants'; interface ArtTherapyTabListProps { @@ -36,6 +38,71 @@ const artConcepts = new Map([ ['3e69cb60-2943-410f-83d4-b359ae83fefd', 'Restart ART therapy'], ]); +interface ARTDateConcepts { + artTherapyDateTime_UUID: string; + switchDateUUID: string; + substitutionDateUUID: string; + artStopDateUUID: string; + dateRestartedUUID: string; +} + +function getLatestARTDateConcept(encounter, dateConcepts: ARTDateConcepts): string { + let artStartDate = findObs(encounter, dateConcepts.artTherapyDateTime_UUID); + let artSubstitutionDate = findObs(encounter, dateConcepts.substitutionDateUUID); + let artSwitchDate = findObs(encounter, dateConcepts.switchDateUUID); + let artStopDate = findObs(encounter, dateConcepts.artStopDateUUID); + let artRestartDate = findObs(encounter, dateConcepts.dateRestartedUUID); + + artStartDate = artStartDate ? artStartDate.value : null; + artSubstitutionDate = artSubstitutionDate ? artSubstitutionDate.value : null; + artSwitchDate = artSwitchDate ? artSwitchDate.value : null; + artStopDate = artStopDate ? artStopDate.value : null; + artRestartDate = artRestartDate ? artRestartDate.value : null; + + let latestDateConcept: string = dateConcepts.artTherapyDateTime_UUID; + let latestDate = artStartDate; + if (artSubstitutionDate > latestDate) { + latestDateConcept = dateConcepts.substitutionDateUUID; + latestDate = artSubstitutionDate; + } + if (artSwitchDate > latestDate) { + latestDate = artSwitchDate; + latestDateConcept = dateConcepts.switchDateUUID; + } + if (artStopDate > latestDate) { + latestDate = artStopDate; + latestDateConcept = dateConcepts.artStopDateUUID; + } + if (artRestartDate > latestDate) { + latestDate = artRestartDate; + latestDateConcept = dateConcepts.dateRestartedUUID; + } + + return latestDateConcept; +} + +function getARTReasonConcept(encounter, dateConcepts: ARTDateConcepts): string { + const latestDateConcept: string = getLatestARTDateConcept(encounter, dateConcepts); + let artReaseonConcept = ''; + switch (latestDateConcept) { + case dateConcepts.artStopDateUUID: + artReaseonConcept = stopReasonUUID; + break; + case dateConcepts.substitutionDateUUID: + artReaseonConcept = substituteReasonUUID; + break; + case dateConcepts.switchDateUUID: + artReaseonConcept = switchReasonUUID; + break; + case dateConcepts.dateRestartedUUID: + artReaseonConcept = restartReasonUUID; + break; + default: + artReaseonConcept = ''; + } + return artReaseonConcept; +} + const columns: EncounterListColumn[] = [ { key: 'initiationDate', From 144416949a3d165ef8e6a13688ba1d5ee593fcd1 Mon Sep 17 00:00:00 2001 From: AJAL ODORA JONATHAN <43242517+ODORA0@users.noreply.github.com> Date: Thu, 24 Mar 2022 09:10:20 +0300 Subject: [PATCH 17/23] OHRI-683 Intimate Partner Violence Form and list added to the general counselling section --- src/constants.ts | 7 + src/packages/forms-registry.ts | 4 + .../intimate-partner/1.0.json | 317 ++++++++++++++++++ .../intimate-partner-violence.component.tsx | 93 ++++- 4 files changed, 416 insertions(+), 5 deletions(-) create mode 100644 src/packages/hiv/forms/care-and-treatment/intimate-partner/1.0.json diff --git a/src/constants.ts b/src/constants.ts index afb552ade..3c5887f14 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -178,3 +178,10 @@ export const ContactDate_UUID = '160753AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const ContactMethod_UUID = '59c023dd-eed2-4b11-8c34-b88e9439db3c'; export const ContactOutcome_UUID = 'bc45edbd-11e7-4888-ad7d-4ec3dd8cdcf6'; export const PatientTracingEncounterType_UUID = '0cd5d4cb-204e-419a-9dd7-1e18e939ce4c'; + +//Intimate Partner +export const IntimatePartnerEncounterType_UUID = '881fff34-b4a9-4d11-b2f5-a8a23a9f402b'; +export const ThreatenedToHurt_UUID = 'bd86f7ee-1d5f-4f5d-aa0f-4680aa6e65cb'; +export const SexuallyMolested_UUID = '1246AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; +export const howOftenThreatened_UUID = '953f6271-57ef-414e-bdba-fe9e0246db58'; +export const howOftenSexuallyMolested_UUID = '1dd53a22-2e8f-425b-8ba4-59172ed3fafe'; diff --git a/src/packages/forms-registry.ts b/src/packages/forms-registry.ts index 14f61c29a..2d6d848c3 100644 --- a/src/packages/forms-registry.ts +++ b/src/packages/forms-registry.ts @@ -19,6 +19,7 @@ import covid_case_form_v_1_0 from './covid/forms/case-form/1.0.json'; import death_form_v_1_0 from './hiv/forms/care-and-treatment/death-form/1.0.json'; import transfer_out_v_1_0 from './hiv/forms/care-and-treatment/transfer-out/1.0.json'; import patient_tracing_v_1_0 from './hiv/forms/care-and-treatment/patient-tracing/1.0.json'; +import intimate_partner_v_1_0 from './hiv/forms/care-and-treatment/intimate-partner/1.0.json'; export default { hiv: { @@ -50,6 +51,9 @@ export default { patient_tracing: { '1.0': patient_tracing_v_1_0, }, + intimate_partner: { + '1.0': intimate_partner_v_1_0, + }, }, covid: { covid_assessment: { diff --git a/src/packages/hiv/forms/care-and-treatment/intimate-partner/1.0.json b/src/packages/hiv/forms/care-and-treatment/intimate-partner/1.0.json new file mode 100644 index 000000000..c4bea5d3c --- /dev/null +++ b/src/packages/hiv/forms/care-and-treatment/intimate-partner/1.0.json @@ -0,0 +1,317 @@ +{ + "name":"Intimate Partner Violence Form", + "pages":[ + { + "label":"IPV Screening", + "sections":[ + { + "label":"Introduction", + "isExpanded":"true", + "questions":[ + { + "type":"markdown", + "questionOptions":{ + "rendering":"markdown" + }, + "id":"fooMarkdown", + "value":[ + "**This form is used to:** Document intimate partner abuse or aggression that occurs in a romantic relationship." + ] + } + ] + }, + { + "label":"IPV Assessment", + "isExpanded":"true", + "questions":[ + { + "label":"Within the past year, has someone ever hit, kicked, slapped, or otherwise physically hurt you?", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"2a228c6a-1575-43d7-9d42-9b68d0629f46", + "answers":[ + { + "label":"Yes", + "concept":"cf82933b-3f3f-45e7-a5ab-5d31aaee3da3" + }, + { + "label":"No", + "concept":"488b58ff-64f5-4f8a-8979-fa79940b1594" + } + ] + }, + "id":"everBeenAssaulted" + }, + { + "label":"By who", + "type":"obs", + "questionOptions":{ + "rendering":"checkbox", + "concept":"feba905e-d208-4124-8de9-58391fe88367", + "answers":[ + { + "concept":"5617AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Partner or spouse", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"5617" + }, + { + "type":"SNOMED-CT", + "value":"127848009" + }, + { + "type":"CIEL", + "value":"5617" + } + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown Person", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"SNOMED-CT", + "value":"261665006" + }, + { + "type":"PIH", + "value":"1067" + } + ] + } + ] + }, + "id":"byWhoAssaulted" + }, + { + "label":"How often?", + "type":"obs", + "questionOptions":{ + "rendering":"number", + "concept":"513260c4-5f9d-4a28-9665-155b61544f5f", + "max":"1000", + "min":"0", + "showDate":"false" + }, + "id":"howOftenAssaulted" + }, + { + "label":"Has someone ever threatened to hurt you?", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"bd86f7ee-1d5f-4f5d-aa0f-4680aa6e65cb", + "answers":[ + { + "label":"Yes", + "concept":"cf82933b-3f3f-45e7-a5ab-5d31aaee3da3" + }, + { + "label":"No", + "concept":"488b58ff-64f5-4f8a-8979-fa79940b1594" + } + ], + "conceptMappings":[ + + ] + }, + "id":"everBeenThreatened" + }, + { + "label":"By who?", + "type":"obs", + "questionOptions":{ + "rendering":"checkbox", + "concept":"feba905e-d208-4124-8de9-58391fe88367", + "answers":[ + { + "concept":"5617AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Partner or spouse", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"5617" + }, + { + "type":"SNOMED-CT", + "value":"127848009" + }, + { + "type":"CIEL", + "value":"5617" + } + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown Person", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"SNOMED-CT", + "value":"261665006" + }, + { + "type":"PIH", + "value":"1067" + } + ] + } + ] + }, + "behaviours":[ + + ], + "id":"threatenedByWho" + }, + { + "label":"How often?", + "type":"obs", + "questionOptions":{ + "rendering":"number", + "concept":"953f6271-57ef-414e-bdba-fe9e0246db58", + "max":"1000", + "min":"0", + "showDate":"false" + }, + "id":"howOftenThreatened" + }, + { + "label":"Has someone ever forced you to do something sexually that made you feel uncomfortable?", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"1246AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "answers":[ + { + "label":"Yes", + "concept":"cf82933b-3f3f-45e7-a5ab-5d31aaee3da3" + }, + { + "label":"No", + "concept":"488b58ff-64f5-4f8a-8979-fa79940b1594" + } + ], + "conceptMappings":[ + + ] + }, + "id":"everForcedSexually" + }, + { + "label":"By who?", + "type":"obs", + "questionOptions":{ + "rendering":"checkbox", + "concept":"feba905e-d208-4124-8de9-58391fe88367", + "answers":[ + { + "concept":"5617AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Partner or spouse", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"5617" + }, + { + "type":"SNOMED-CT", + "value":"127848009" + }, + { + "type":"CIEL", + "value":"5617" + } + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown Person", + "conceptMappings":[ + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"SNOMED-CT", + "value":"261665006" + }, + { + "type":"PIH", + "value":"1067" + } + ] + } + ] + }, + "behaviours":[ + + ], + "id":"SexuallyMolestedbyWho" + }, + { + "label":"How often?", + "type":"obs", + "questionOptions":{ + "rendering":"number", + "concept":"1dd53a22-2e8f-425b-8ba4-59172ed3fafe", + "max":"1000", + "min":"0", + "showDate":"false" + }, + "id":"howOftenSexuallyMolested" + } + ] + }, + { + "label":"Notes", + "isExpanded":"true", + "questions":[ + { + "label":"Enter comments", + "type":"obs", + "questionOptions":{ + "rendering":"textarea", + "concept":"165095AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "rows":"" + }, + "id":"Note" + } + ] + } + ] + } + ], + "availableIntents": [ + { + "intent": "*", + "display": "Intimate Partner Violence Form" + } + ], + "processor":"EncounterFormProcessor", + "uuid":"xxxx", + "referencedForms":[], + "encounterType": "881fff34-b4a9-4d11-b2f5-a8a23a9f402b", + "allowUnspecifiedAll": true + } \ No newline at end of file diff --git a/src/pages/general-counselling/tabs/intimate-partner-violence.component.tsx b/src/pages/general-counselling/tabs/intimate-partner-violence.component.tsx index 263183a2d..5067133b0 100644 --- a/src/pages/general-counselling/tabs/intimate-partner-violence.component.tsx +++ b/src/pages/general-counselling/tabs/intimate-partner-violence.component.tsx @@ -1,21 +1,104 @@ import React, { useEffect, useState } from 'react'; import { useTranslation } from 'react-i18next'; import EmptyState from '../../../components/empty-state/empty-state.component'; +import EncounterList, { + EncounterListColumn, + findObs, + getObsFromEncounter, +} from '../../../components/encounter-list/encounter-list.component'; +import { + howOftenSexuallyMolested_UUID, + howOftenThreatened_UUID, + IntimatePartnerEncounterType_UUID, + SexuallyMolested_UUID, + ThreatenedToHurt_UUID, +} from '../../../constants'; interface IntimatePartnerViolenceListProps { patientUuid: string; } +const columns: EncounterListColumn[] = [ + { + key: 'threatenedToHurt', + header: 'Threatened to Hurt', + getValue: encounter => { + const obs = findObs(encounter, ThreatenedToHurt_UUID); + if (!obs) { + return '--'; + } + if (obs.value.uuid == 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3') { + return 'Yes'; + } else { + return 'No'; + } + }, + }, + { + key: 'howOftenThreatenedToHurt', + header: 'How Often Threatened to Hurt', + getValue: encounter => { + return getObsFromEncounter(encounter, howOftenThreatened_UUID); + }, + }, + { + key: 'sexuallyMolested', + header: 'Sexually Molested', + getValue: encounter => { + const obs = findObs(encounter, SexuallyMolested_UUID); + if (!obs) { + return '--'; + } + if (obs.value.uuid == 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3') { + return 'Yes'; + } else { + return 'No'; + } + }, + }, + { + key: 'howOftenSexuallyMolested', + header: 'How Often Sexually Molested', + getValue: encounter => { + return getObsFromEncounter(encounter, howOftenSexuallyMolested_UUID); + }, + }, + { + key: 'actions', + header: 'Actions', + getValue: encounter => [ + { + form: { name: 'intimate_partner', package: 'hiv' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'View Details', + mode: 'view', + }, + { + form: { name: 'intimate_partner', package: 'hiv' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'Edit', + mode: 'edit', + }, + ], + }, +]; + const IntimatePartnerViolenceList: React.FC = ({ patientUuid }) => { const { t } = useTranslation(); - const headerTitle = t('intimatePartnerViolence', 'Intimate Partner Violence'); const displayText = t('intimatePartnerViolence', 'Intimate Partner Violence'); - return ( - <> - - + ); }; From 82737ee75544a2afd7b2ef7d750154befc99efff Mon Sep 17 00:00:00 2001 From: AJAL ODORA JONATHAN <43242517+ODORA0@users.noreply.github.com> Date: Thu, 24 Mar 2022 10:04:14 +0300 Subject: [PATCH 18/23] OHRI-730 Disclosure Tab List under General Counselling --- .../tabs/disclosure.component.tsx | 57 ++++++++++++++++++- 1 file changed, 54 insertions(+), 3 deletions(-) diff --git a/src/pages/general-counselling/tabs/disclosure.component.tsx b/src/pages/general-counselling/tabs/disclosure.component.tsx index 95626cbb3..c954b03b4 100644 --- a/src/pages/general-counselling/tabs/disclosure.component.tsx +++ b/src/pages/general-counselling/tabs/disclosure.component.tsx @@ -1,11 +1,56 @@ import React, { useEffect, useState } from 'react'; import { useTranslation } from 'react-i18next'; import EmptyState from '../../../components/empty-state/empty-state.component'; +import EncounterList, { + EncounterListColumn, + getObsFromEncounter, +} from '../../../components/encounter-list/encounter-list.component'; +import { deathFormEncounterType_UUID } from '../../../constants'; interface DisclosureListProps { patientUuid: string; } +const columnsLab: EncounterListColumn[] = [ + { + key: 'contactDate', + header: 'Disclosure Date', + getValue: encounter => { + return getObsFromEncounter(encounter, true); + }, + }, + { + key: 'contactMethod', + header: 'Disclosure Stage', + getValue: encounter => { + return getObsFromEncounter(encounter, true); + }, + }, + { + key: 'actions', + header: 'Actions', + getValue: encounter => { + const baseActions = [ + { + form: { name: 'death_form', package: 'hiv' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'View Details', + mode: 'view', + }, + { + form: { name: 'death_form', package: 'hiv' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'Edit Details', + mode: 'edit', + }, + ]; + return baseActions; + }, + }, +]; + const DisclosureList: React.FC = ({ patientUuid }) => { const { t } = useTranslation(); @@ -13,9 +58,15 @@ const DisclosureList: React.FC = ({ patientUuid }) => { const displayText = t('disclosure', 'Disclosure'); return ( - <> - - + ); }; From 662725d8e28d969b9997f0ca6d7b918c1b533114 Mon Sep 17 00:00:00 2001 From: AJAL ODORA JONATHAN <43242517+ODORA0@users.noreply.github.com> Date: Thu, 24 Mar 2022 10:56:16 +0300 Subject: [PATCH 19/23] OHRI-726 Intimate Partner Violence Form updated with business rules --- .../intimate-partner/1.0.json | 127 +++++++++++++++--- 1 file changed, 110 insertions(+), 17 deletions(-) diff --git a/src/packages/hiv/forms/care-and-treatment/intimate-partner/1.0.json b/src/packages/hiv/forms/care-and-treatment/intimate-partner/1.0.json index c4bea5d3c..6fbd7c9e7 100644 --- a/src/packages/hiv/forms/care-and-treatment/intimate-partner/1.0.json +++ b/src/packages/hiv/forms/care-and-treatment/intimate-partner/1.0.json @@ -15,7 +15,7 @@ }, "id":"fooMarkdown", "value":[ - "**This form is used to:** Document intimate partner abuse or aggression that occurs in a romantic relationship." + "**Introduction:** Use this form to Document intimate partner abuse or aggression that occurs in a romantic relationship." ] } ] @@ -41,7 +41,18 @@ } ] }, - "id":"everBeenAssaulted" + "id":"everBeenAssaulted", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [] + } + ] }, { "label":"By who", @@ -92,7 +103,18 @@ } ] }, - "id":"byWhoAssaulted" + "id":"byWhoAssaulted", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('everBeenAssaulted','cf82933b-3f3f-45e7-a5ab-5d31aaee3da3')" + }, + "validators": [] + } + ] }, { "label":"How often?", @@ -104,7 +126,18 @@ "min":"0", "showDate":"false" }, - "id":"howOftenAssaulted" + "id":"howOftenAssaulted", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('everBeenAssaulted','cf82933b-3f3f-45e7-a5ab-5d31aaee3da3')" + }, + "validators": [] + } + ] }, { "label":"Has someone ever threatened to hurt you?", @@ -126,7 +159,18 @@ ] }, - "id":"everBeenThreatened" + "id":"everBeenThreatened", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [] + } + ] }, { "label":"By who?", @@ -176,11 +220,19 @@ ] } ] - }, - "behaviours":[ - - ], - "id":"threatenedByWho" + }, + "id":"threatenedByWho", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('everBeenThreatened','cf82933b-3f3f-45e7-a5ab-5d31aaee3da3')" + }, + "validators": [] + } + ] }, { "label":"How often?", @@ -192,7 +244,18 @@ "min":"0", "showDate":"false" }, - "id":"howOftenThreatened" + "id":"howOftenThreatened", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('everBeenThreatened','cf82933b-3f3f-45e7-a5ab-5d31aaee3da3')" + }, + "validators": [] + } + ] }, { "label":"Has someone ever forced you to do something sexually that made you feel uncomfortable?", @@ -214,7 +277,18 @@ ] }, - "id":"everForcedSexually" + "id":"everForcedSexually", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [] + } + ] }, { "label":"By who?", @@ -265,10 +339,18 @@ } ] }, - "behaviours":[ - - ], - "id":"SexuallyMolestedbyWho" + "id":"SexuallyMolestedbyWho", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('everForcedSexually','cf82933b-3f3f-45e7-a5ab-5d31aaee3da3')" + }, + "validators": [] + } + ] }, { "label":"How often?", @@ -280,7 +362,18 @@ "min":"0", "showDate":"false" }, - "id":"howOftenSexuallyMolested" + "id":"howOftenSexuallyMolested", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('everForcedSexually','cf82933b-3f3f-45e7-a5ab-5d31aaee3da3')" + }, + "validators": [] + } + ] } ] }, From 82584a3fc1af107412d8b4a5aefe66a683aec9f6 Mon Sep 17 00:00:00 2001 From: Jovan Ssebaggala Date: Thu, 24 Mar 2022 14:37:51 +0300 Subject: [PATCH 20/23] OHRI-747 HTS-WHO form save --- src/packages/hiv/forms/hts-who/1.0.json | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/src/packages/hiv/forms/hts-who/1.0.json b/src/packages/hiv/forms/hts-who/1.0.json index 9077375db..4a70bbd61 100644 --- a/src/packages/hiv/forms/hts-who/1.0.json +++ b/src/packages/hiv/forms/hts-who/1.0.json @@ -2646,17 +2646,9 @@ "type": "PIH", "value": "1065" }, - { - "type": "SNOMED-CT", - "value": "373066001" - }, { "type": "SNOMED CT", "value": "373066001" - }, - { - "type": "PIH-Malawi", - "value": "1065" } ] }, @@ -2679,10 +2671,6 @@ { "type": "SNOMED-CT", "value": "373067005" - }, - { - "type": "PIH-Malawi", - "value": "1066" } ] }, @@ -2701,11 +2689,7 @@ { "type": "PIH", "value": "1067" - }, - { - "type": "SNOMED-CT", - "value": "261665006" - }, + }, { "type": "SNOMED CT", "value": "261665006" From 482800db1de58328a22accb5e8bb71f576b2f366 Mon Sep 17 00:00:00 2001 From: AJAL ODORA JONATHAN <43242517+ODORA0@users.noreply.github.com> Date: Thu, 24 Mar 2022 14:41:24 +0300 Subject: [PATCH 21/23] OHRI-751 Contact Tracing Form and list added to the partner notification services --- src/constants.ts | 6 + src/packages/forms-registry.ts | 4 + .../contact-tracing/1.0.json | 1117 +++++++++++++++++ .../tabs/contact-tracing.component.tsx | 21 +- 4 files changed, 1140 insertions(+), 8 deletions(-) create mode 100644 src/packages/hiv/forms/care-and-treatment/contact-tracing/1.0.json diff --git a/src/constants.ts b/src/constants.ts index bc790db7b..0f2692406 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -188,3 +188,9 @@ export const ThreatenedToHurt_UUID = 'bd86f7ee-1d5f-4f5d-aa0f-4680aa6e65cb'; export const SexuallyMolested_UUID = '1246AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; export const howOftenThreatened_UUID = '953f6271-57ef-414e-bdba-fe9e0246db58'; export const howOftenSexuallyMolested_UUID = '1dd53a22-2e8f-425b-8ba4-59172ed3fafe'; + +//Contact Tracing +export const ContactTracingEncounterType_UUID = '570e9e42-4306-41dc-9bf8-634bbc70a524'; +export const ContactTracingDate_UUID = '160753AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'; +export const ContactTracingMethod_UUID = '59c023dd-eed2-4b11-8c34-b88e9439db3c'; +export const ContactTracingOutcome_UUID = '36a3e671-9d60-4109-b41f-046f44f4b389'; diff --git a/src/packages/forms-registry.ts b/src/packages/forms-registry.ts index 2d6d848c3..dd5d1746a 100644 --- a/src/packages/forms-registry.ts +++ b/src/packages/forms-registry.ts @@ -20,6 +20,7 @@ import death_form_v_1_0 from './hiv/forms/care-and-treatment/death-form/1.0.json import transfer_out_v_1_0 from './hiv/forms/care-and-treatment/transfer-out/1.0.json'; import patient_tracing_v_1_0 from './hiv/forms/care-and-treatment/patient-tracing/1.0.json'; import intimate_partner_v_1_0 from './hiv/forms/care-and-treatment/intimate-partner/1.0.json'; +import contact_tracing_v_1_0 from './hiv/forms/care-and-treatment/contact-tracing/1.0.json'; export default { hiv: { @@ -54,6 +55,9 @@ export default { intimate_partner: { '1.0': intimate_partner_v_1_0, }, + contact_tracing: { + '1.0': contact_tracing_v_1_0, + }, }, covid: { covid_assessment: { diff --git a/src/packages/hiv/forms/care-and-treatment/contact-tracing/1.0.json b/src/packages/hiv/forms/care-and-treatment/contact-tracing/1.0.json new file mode 100644 index 000000000..ad852f0bb --- /dev/null +++ b/src/packages/hiv/forms/care-and-treatment/contact-tracing/1.0.json @@ -0,0 +1,1117 @@ +{ + "name":"Contact Tracing Form", + "pages":[ + { + "label":"Introduction", + "sections":[ + { + "label":"", + "isExpanded":"true", + "questions":[ + { + "type":"markdown", + "questionOptions":{ + "rendering":"markdown" + }, + "id":"fooMarkdown", + "value":[ + "**Use this form to:** Trace a contact of an index client (Child/Sex partner/Someone who they shared a needle with) " + ] + } + ] + } + ] + }, + { + "label":"Contact Tracing", + "sections":[ + { + "label":"Contact Tracing Details", + "isExpanded":"true", + "questions":[ + { + "label":"Contact date", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"160753AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "conceptMappings":[ + { + "type":"CIEL", + "value":"160753" + }, + { + "type":"CIEL", + "value":"160753" + }, + { + "type":"SNOMED-CT", + "value":"439771001" + }, + { + "type":"SNOMED-CT", + "value":"439771001" + } + ] + }, + "id":"contactDate", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [ + { + "type": "date", + "allowFutureDates": "false" + }, + { + "type": "js_expression", + "failsWhenExpression": "isDateBefore(myValue, '1980-01-01') || myValue >= today()" } + ] + } + ] + }, + { + "label":"Contact Method", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"59c023dd-eed2-4b11-8c34-b88e9439db3c", + "answers":[ + { + "concept":"166457AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Physical contact/client tracing", + "conceptMappings":[ + + ] + }, + { + "concept":"166458AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Telephone contact/client tracing", + "conceptMappings":[ + + ] + }, + { + "concept":"5622AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Other non-coded", + "conceptMappings":[ + { + "type":"PIH-Malawi", + "value":"6408" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"OTHER" + }, + { + "type":"PIH", + "value":"5622" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"OTHER" + }, + { + "type":"PIH-Malawi", + "value":"6408" + }, + { + "type":"SNOMED-MVP", + "value":"56221000105001" + }, + { + "type":"AMPATH", + "value":"5622" + }, + { + "type":"PIH", + "value":"5622" + }, + { + "type":"SNOMED-MVP", + "value":"56221000105001" + }, + { + "type":"CIEL", + "value":"5622" + }, + { + "type":"AMPATH", + "value":"5622" + }, + { + "type":"SNOMED-CT", + "value":"74964007" + } + ] + } + ] + }, + "id":"contactMethod", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [] + } + ] + } + ] + }, + { + "label":"Outcome Contact", + "isExpanded":"true", + "questions":[ + { + "label":"Contacted Successfully", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"911d08b4-b523-46e4-8b65-e6924e95d015", + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED-CT", + "value":"373066001" + }, + { + "type":"PIH-Malawi", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + } + ] + }, + { + "concept":"1066AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"No", + "conceptMappings":[ + { + "type":"PIH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"PIH", + "value":"1066" + } + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"SNOMED-CT", + "value":"261665006" + }, + { + "type":"PIH", + "value":"1067" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"UNKNOWN" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"PIH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + } + ] + } + ] + }, + "id":"patientContacted", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [] + } + ] + }, + { + "label":"Outcome", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"36a3e671-9d60-4109-b41f-046f44f4b389", + "answers":[ + { + "concept":"83f1c235-de6f-4141-8d8d-73a917b781de", + "label":"Contact came for HTS", + "conceptMappings":[ + + ] + }, + { + "concept":"56f6a5a4-7ef9-4af3-a250-26b3894e711b", + "label":"Contact will test elsewhere", + "conceptMappings":[ + + ] + }, + { + "concept":"e7a0e18e-56e2-49da-b518-673f13c7bfba", + "label":"Refused Test", + "conceptMappings":[ + + ] + }, + { + "concept":"5566AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Partner confirmed HIV+", + "conceptMappings":[ + { + "type":"CIEL", + "value":"5566" + }, + { + "type":"AMPATH", + "value":"5566" + } + ] + } + ] + }, + "id":"outcomePatient", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('patientContacted','1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA')" + }, + "validators": [] + } + ] + } + ] + }, + { + "label":"HIV Testing", + "isExpanded":"true", + "questions":[ + { + "label":"Contact booked for HIV test", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"24c9e221-bc34-4a41-8a2e-ffb7331890e1", + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED-CT", + "value":"373066001" + }, + { + "type":"PIH-Malawi", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + } + ] + }, + { + "concept":"1066AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"No", + "conceptMappings":[ + { + "type":"PIH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"PIH", + "value":"1066" + } + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"SNOMED-CT", + "value":"261665006" + }, + { + "type":"PIH", + "value":"1067" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"UNKNOWN" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"PIH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + } + ] + } + ] + }, + "id":"contactBooked", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('outcomePatient','56f6a5a4-7ef9-4af3-a250-26b3894e711b')" + }, + "validators": [] + } + ] + }, + { + "label":"Date booked for HIV test", + "type":"obs", + "questionOptions":{ + "rendering":"date", + "concept":"04dcb442-384c-41b5-9f0e-2fe24b977cb2", + "weeksList":"" + }, + "id":"dateBooked", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('outcomePatient','56f6a5a4-7ef9-4af3-a250-26b3894e711b')" + }, + "validators": [ + { + "type": "date", + "allowFutureDates": "false" + }, + { + "type": "js_expression", + "failsWhenExpression": "myValue <= useFieldValue('contactDate')" + } + ] + } + ] + }, + { + "label":"Contact Tested for HIV", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"161557AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "conceptMappings":[ + { + "type":"CIEL", + "value":"161557" + } + ], + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED-CT", + "value":"373066001" + }, + { + "type":"PIH-Malawi", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + } + ] + }, + { + "concept":"1066AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"No", + "conceptMappings":[ + { + "type":"PIH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"PIH", + "value":"1066" + } + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"SNOMED-CT", + "value":"261665006" + }, + { + "type":"PIH", + "value":"1067" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"UNKNOWN" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"PIH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + } + ] + } + ] + }, + "id":"contactHIVTesting", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('outcomePatient','83f1c235-de6f-4141-8d8d-73a917b781de')" + }, + "validators": [] + } + ] + }, + { + "label":"Contact HIV Status", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"1436AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "conceptMappings":[ + { + "type":"SNOMED-MVP", + "value":"14361000105003" + }, + { + "type":"AMPATH", + "value":"2313" + }, + { + "type":"SNOMED-CT", + "value":"278977008" + }, + { + "type":"PIH", + "value":"3082" + }, + { + "type":"PIH", + "value":"3082" + }, + { + "type":"SNOMED-MVP", + "value":"14361000105003" + }, + { + "type":"CIEL", + "value":"1436" + } + ], + "answers":[ + { + "concept":"703AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Positive", + "conceptMappings":[ + { + "type":"PIH", + "value":"703" + }, + { + "type":"AMPATH", + "value":"704" + }, + { + "type":"AMPATH", + "value":"703" + }, + { + "type":"SNOMED-CT", + "value":"10828004" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"POSITIVE" + } + ] + }, + { + "concept":"664AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Negative", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"664" + }, + { + "type":"PIH", + "value":"664" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"NEGATIVE" + }, + { + "type":"SNOMED-CT", + "value":"260385009" + }, + { + "type":"AMPATH", + "value":"664" + }, + { + "type":"CIEL", + "value":"664" + }, + { + "type":"SNOMED-CT", + "value":"260385009" + }, + { + "type":"PIH", + "value":"664" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"NEGATIVE" + }, + { + "type":"AMPATH", + "value":"665" + }, + { + "type":"AMPATH", + "value":"665" + } + ] + }, + { + "concept":"1138AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Indeterminate", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1138" + }, + { + "type":"CIEL", + "value":"1138" + }, + { + "type":"AMPATH", + "value":"1138" + }, + { + "type":"SNOMED-CT", + "value":"82334004" + }, + { + "type":"SNOMED-CT", + "value":"82334004" + } + ] + }, + { + "concept":"1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unknown", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"CIEL", + "value":"1067" + }, + { + "type":"SNOMED-CT", + "value":"261665006" + }, + { + "type":"PIH", + "value":"1067" + }, + { + "type":"org.openmrs.module.mdrtb", + "value":"UNKNOWN" + }, + { + "type":"AMPATH", + "value":"1067" + }, + { + "type":"PIH", + "value":"1067" + }, + { + "type":"SNOMED CT", + "value":"CT: 261665006" + } + ] + } + ] + }, + "id":"contactHIVStatus", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('outcomePatient','83f1c235-de6f-4141-8d8d-73a917b781de')" + }, + "validators": [] + } + ] + } + ], + "behaviours": [ + { + "intent": "*", + "required": "false", + "unspecified": "false", + "hide": { + "hideWhenExpression": "!includes('outcomePatient','56f6a5a4-7ef9-4af3-a250-26b3894e711b') || outcomePatient !== '83f1c235-de6f-4141-8d8d-73a917b781de' " + }, + "validators": [] + } + ] + } + ] + }, + { + "label":"Outcome", + "sections":[ + { + "label":"Final Outcome Contact", + "isExpanded":"true", + "questions":[ + { + "label":"Final Outcome reached (After successful or multiple unsuccessful tracing attempts)", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"eeba884c-67fc-4f03-be2e-8dd3eb64ae10", + "answers":[ + { + "concept":"1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Yes", + "conceptMappings":[ + { + "type":"AMPATH", + "value":"1065" + }, + { + "type":"SNOMED CT", + "value":"CT: 373066001" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"CIEL", + "value":"1065" + }, + { + "type":"PIH", + "value":"1065" + }, + { + "type":"SNOMED-CT", + "value":"373066001" + }, + { + "type":"PIH-Malawi", + "value":"1065" + }, + { + "type":"AMPATH", + "value":"1065" + } + ] + }, + { + "concept":"1066AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"No", + "conceptMappings":[ + { + "type":"PIH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"PIH-Malawi", + "value":"1066" + }, + { + "type":"AMPATH", + "value":"1066" + }, + { + "type":"SNOMED-CT", + "value":"373067005" + }, + { + "type":"PIH", + "value":"1066" + } + ] + } + ] + }, + "id":"finalOutcomeReached", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "false" + }, + "validators": [] + } + ] + }, + { + "label":"Final outcome contact tracking", + "type":"obs", + "questionOptions":{ + "rendering":"radio", + "concept":"a51f1923-80ff-422a-8c22-5d6fb39bcf67", + "answers":[ + { + "concept":"161557AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Partner HIV tested", + "conceptMappings":[ + { + "type":"CIEL", + "value":"161557" + } + ] + }, + { + "concept":"5566AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Partner confirmed HIV+", + "conceptMappings":[ + { + "type":"CIEL", + "value":"5566" + }, + { + "type":"AMPATH", + "value":"5566" + } + ] + }, + { + "concept":"3e25107e-4973-4cab-9892-ed030b90f6dd", + "label":"Will test elsewhere", + "conceptMappings":[ + + ] + }, + { + "concept":"34a71cb0-5663-4e48-84f2-7150f26f4398", + "label":"Contact is far from this facility", + "conceptMappings":[ + + ] + }, + { + "concept":"4d1fbba8-478c-4876-abee-bffe6ee060f7", + "label":"Contact unwilling to come", + "conceptMappings":[ + + ] + }, + { + "concept":"160432AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Dead", + "conceptMappings":[ + + ] + }, + { + "concept":"166994AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label":"Unsuccessful", + "conceptMappings":[ + + ] + } + ] + }, + "id":"finalContactOutcome", + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "!includes('finalOutcomeReached','1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA')" + }, + "validators": [] + } + ] + } + ] + } + ] + }, + { + "label":"Notes", + "sections":[ + { + "label":"Contact tracking notes", + "isExpanded":"true", + "questions":[ + { + "label":"Notes", + "type":"obs", + "questionOptions":{ + "rendering":"textarea", + "concept":"165095AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "rows":"", + "conceptMappings":[ + { + "type":"CIEL", + "value":"165095" + } + ] + }, + "id":"contactTracingNotes" + } + ] + } + ] + } + ], + "availableIntents": [ + { + "intent": "*", + "display": "Contact Tracing Form" + } + ], + "processor":"EncounterFormProcessor", + "uuid":"xxxx", + "referencedForms":[], + "encounterType": "570e9e42-4306-41dc-9bf8-634bbc70a524", + "allowUnspecifiedAll": true + } \ No newline at end of file diff --git a/src/pages/partner-notification-services/tabs/contact-tracing.component.tsx b/src/pages/partner-notification-services/tabs/contact-tracing.component.tsx index 3de0c4031..9f3b27d09 100644 --- a/src/pages/partner-notification-services/tabs/contact-tracing.component.tsx +++ b/src/pages/partner-notification-services/tabs/contact-tracing.component.tsx @@ -5,7 +5,12 @@ import EncounterList, { EncounterListColumn, getObsFromEncounter, } from '../../../components/encounter-list/encounter-list.component'; -import { deathFormEncounterType_UUID } from '../../../constants'; +import { + ContactTracingDate_UUID, + ContactTracingEncounterType_UUID, + ContactTracingMethod_UUID, + ContactTracingOutcome_UUID, +} from '../../../constants'; interface ContactTracingListProps { patientUuid: string; @@ -16,21 +21,21 @@ const columnsLab: EncounterListColumn[] = [ key: 'contactDate', header: 'Contact Date', getValue: encounter => { - return getObsFromEncounter(encounter, true); + return getObsFromEncounter(encounter, ContactTracingDate_UUID, true); }, }, { key: 'contactMethod', header: 'Contact Method', getValue: encounter => { - return getObsFromEncounter(encounter, true); + return getObsFromEncounter(encounter, ContactTracingMethod_UUID); }, }, { key: 'contactOutcome', header: 'Contact Outcome', getValue: encounter => { - return getObsFromEncounter(encounter, true); + return getObsFromEncounter(encounter, ContactTracingOutcome_UUID); }, }, @@ -40,14 +45,14 @@ const columnsLab: EncounterListColumn[] = [ getValue: encounter => { const baseActions = [ { - form: { name: 'death_form', package: 'hiv' }, + form: { name: 'contact_tracing', package: 'hiv' }, encounterUuid: encounter.uuid, intent: '*', label: 'View Details', mode: 'view', }, { - form: { name: 'death_form', package: 'hiv' }, + form: { name: 'contact_tracing', package: 'hiv' }, encounterUuid: encounter.uuid, intent: '*', label: 'Edit Details', @@ -68,8 +73,8 @@ const ContactTracingList: React.FC = ({ patientUuid }) return ( Date: Thu, 24 Mar 2022 15:48:28 +0300 Subject: [PATCH 22/23] OHRI-732 Partner notification tab contents added --- .../tabs/partner-notification.component.tsx | 79 ++++++++++++++++++- 1 file changed, 76 insertions(+), 3 deletions(-) diff --git a/src/pages/partner-notification-services/tabs/partner-notification.component.tsx b/src/pages/partner-notification-services/tabs/partner-notification.component.tsx index 8f7e2a9e1..31805b250 100644 --- a/src/pages/partner-notification-services/tabs/partner-notification.component.tsx +++ b/src/pages/partner-notification-services/tabs/partner-notification.component.tsx @@ -1,11 +1,78 @@ import React, { useEffect, useState } from 'react'; import { useTranslation } from 'react-i18next'; import EmptyState from '../../../components/empty-state/empty-state.component'; +import EncounterList, { + EncounterListColumn, + getObsFromEncounter, +} from '../../../components/encounter-list/encounter-list.component'; +import { deathFormEncounterType_UUID } from '../../../constants'; interface PartnerNotificationListProps { patientUuid: string; } +const columnsLab: EncounterListColumn[] = [ + { + key: 'Date', + header: 'Date', + getValue: encounter => { + return getObsFromEncounter(encounter, true); + }, + }, + { + key: 'relationshipToIndex', + header: 'Relationship to Index', + getValue: encounter => { + return getObsFromEncounter(encounter, true); + }, + }, + { + key: 'indexType', + header: 'Index Type', + getValue: encounter => { + return getObsFromEncounter(encounter, true); + }, + }, + { + key: 'contactMethod', + header: 'Contact Method', + getValue: encounter => { + return getObsFromEncounter(encounter, true); + }, + }, + { + key: 'contactOutcome', + header: 'Contact Outcome', + getValue: encounter => { + return getObsFromEncounter(encounter, true); + }, + }, + + { + key: 'actions', + header: 'Actions', + getValue: encounter => { + const baseActions = [ + { + form: { name: '', package: '' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'View Details', + mode: 'view', + }, + { + form: { name: '', package: '' }, + encounterUuid: encounter.uuid, + intent: '*', + label: 'Edit Details', + mode: 'edit', + }, + ]; + return baseActions; + }, + }, +]; + const PartnerNotificationList: React.FC = ({ patientUuid }) => { const { t } = useTranslation(); @@ -13,9 +80,15 @@ const PartnerNotificationList: React.FC = ({ patie const displayText = t('partnerNotification', 'Partner Notification'); return ( - <> - - + ); }; From f82504856b6c8d8f0f48ccb4114e9a5b6c71a797 Mon Sep 17 00:00:00 2001 From: smallGod Date: Fri, 25 Mar 2022 09:40:05 +0300 Subject: [PATCH 23/23] OHRI-710 Show/hide entire sections based on more conditions --- src/packages/hiv/forms/hts-who/1.0.json | 891 +++++++++++++++++++----- 1 file changed, 719 insertions(+), 172 deletions(-) diff --git a/src/packages/hiv/forms/hts-who/1.0.json b/src/packages/hiv/forms/hts-who/1.0.json index 4a70bbd61..46ee61a8f 100644 --- a/src/packages/hiv/forms/hts-who/1.0.json +++ b/src/packages/hiv/forms/hts-who/1.0.json @@ -15,7 +15,7 @@ }, "id": "fooMarkdown", "value": [ - "Use this form to perform HIV Testing Services" + "**Use this form to:** perform HIV Testing Services using a three test algorithm" ] }, { @@ -377,13 +377,6 @@ "hide": { "hideWhenExpression": "isEmpty(testingLocation) || testingLocation !== '5995ebd5-11ae-47ca-ac12-bcb8c0117aec'" } - }, - { - "intent": "*", - "required": "false", - "hide": { - "hideWhenExpression": "isEmpty(testingLocation) || testingLocation !== '5995ebd5-11ae-47ca-ac12-bcb8c0117aec'" - } } ], "id": "facilityServiceDeliveryPoint" @@ -590,7 +583,7 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "everTestedForHIV !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" + "hideWhenExpression": "isEmpty(everTestedForHIV) || everTestedForHIV !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" } } ], @@ -669,8 +662,14 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "everTestedForHIV !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" - } + "hideWhenExpression": "isEmpty(everTestedForHIV) || everTestedForHIV !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" + }, + "validators": [ + { + "type": "js_expression", + "failsWhenExpression": "lastHIVTestResult === '6378487b-584d-4422-a6a6-56c8830873ff'" + } + ] } ], "id": "lastHIVTestResult" @@ -809,11 +808,11 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "populationType !== '166431AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + "hideWhenExpression": "isEmpty(populationType) || populationType !== '166431AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" } } ], - "id": "patientPopulationType" + "id": "keyPopulationType" }, { "label": "Sexually active", @@ -964,7 +963,7 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "clientSexualActivity !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" + "hideWhenExpression": "isEmpty(clientSexualActivity) || clientSexualActivity !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" } } ], @@ -1047,7 +1046,7 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "clientSexualActivity !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" + "hideWhenExpression": "isEmpty(clientSexualActivity) || clientSexualActivity !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" } } ], @@ -1056,9 +1055,134 @@ ] }, { - "label": "Pre-Test", + "label": "Pre-Test Information", "isExpanded": "true", "questions": [ + { + "label": "Eligible for HIV Testing", + "type": "obs", + "questionOptions": { + "rendering": "radio", + "concept": "cea67984-d790-4185-b7b4-67736810d365", + "answers": [ + { + "concept": "1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Yes", + "conceptMappings": [ + { + "type": "AMPATH", + "value": "1065" + }, + { + "type": "SNOMED CT", + "value": "CT: 373066001" + }, + { + "type": "PIH", + "value": "1065" + }, + { + "type": "CIEL", + "value": "1065" + }, + { + "type": "PIH", + "value": "1065" + }, + { + "type": "SNOMED-CT", + "value": "373066001" + }, + { + "type": "PIH-Malawi", + "value": "1065" + }, + { + "type": "AMPATH", + "value": "1065" + } + ] + }, + { + "concept": "1066AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "No", + "conceptMappings": [ + { + "type": "PIH", + "value": "1066" + }, + { + "type": "PIH-Malawi", + "value": "1066" + }, + { + "type": "SNOMED-CT", + "value": "373067005" + }, + { + "type": "AMPATH", + "value": "1066" + }, + { + "type": "PIH-Malawi", + "value": "1066" + }, + { + "type": "AMPATH", + "value": "1066" + }, + { + "type": "SNOMED-CT", + "value": "373067005" + }, + { + "type": "PIH", + "value": "1066" + } + ] + }, + { + "concept": "1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Unknown", + "conceptMappings": [ + { + "type": "AMPATH", + "value": "1067" + }, + { + "type": "CIEL", + "value": "1067" + }, + { + "type": "SNOMED-CT", + "value": "261665006" + }, + { + "type": "PIH", + "value": "1067" + }, + { + "type": "org.openmrs.module.mdrtb", + "value": "UNKNOWN" + }, + { + "type": "AMPATH", + "value": "1067" + }, + { + "type": "PIH", + "value": "1067" + }, + { + "type": "SNOMED CT", + "value": "CT: 261665006" + } + ] + } + ] + }, + "id": "eligibleHIVTesting" + }, { "label": "Pretest counselling done", "type": "obs", @@ -1099,7 +1223,10 @@ { "intent": "*", "required": "true", - "unspecified": "true" + "unspecified": "true", + "hide": { + "hideWhenExpression": "isEmpty(eligibleHIVTesting) || eligibleHIVTesting !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } } ], "id": "preTestCounsellingConducted" @@ -1134,7 +1261,7 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "preTestCounsellingConducted !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" + "hideWhenExpression": "isEmpty(preTestCounsellingConducted) || preTestCounsellingConducted !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" } } ], @@ -1179,7 +1306,10 @@ { "intent": "*", "required": "true", - "unspecified": "true" + "unspecified": "true", + "hide": { + "hideWhenExpression": "isEmpty(eligibleHIVTesting) || eligibleHIVTesting !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } } ], "id": "preTestCounselingConsent" @@ -1200,29 +1330,16 @@ "type": "obs", "questionOptions": { "rendering": "checkbox", - "concept": "159800AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "concept": "12a22a0b-f0ed-4f1a-8d70-7c6acda5ae78", "answers": [ { - "concept": "1494AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Fever lasting more than 3 weeks", - "conceptMappings": [ - { - "type": "AMPATH", - "value": "6173" - }, - { - "type": "SNOMED-CT", - "value": "386661006" - }, - { - "type": "ICD-10-WHO", - "value": "R50.9" - } - ] + "concept": "150796AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Abnormal Weight Loss", + "conceptMappings": [] }, { "concept": "159799AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Cough lasting more than 2 weeks", + "label": "cough lasting more than 2 weeks", "conceptMappings": [ { "type": "PIH", @@ -1236,58 +1353,70 @@ "type": "SNOMED-MVP", "value": "1597991000105004" }, + { + "type": "SNOMED-MVP", + "value": "1597991000105004" + }, { "type": "AMPATH", "value": "6171" + }, + { + "type": "PIH", + "value": "2573" } ] }, { - "concept": "138905AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Hemoptysis", + "concept": "1494AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Fever lasting more than three weeks", "conceptMappings": [ { - "type": "3BT", - "value": "10040493" + "type": "AMPATH", + "value": "6173" }, { - "type": "ICD-10-WHO", - "value": "R04.2" + "type": "SNOMED-CT", + "value": "386661006" }, { - "type": "PIH", - "value": "970" + "type": "ICD-10-WHO", + "value": "R50.9" + } + ] + }, + { + "concept": "133027AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Night sweats", + "conceptMappings": [ + { + "type": "SNOMED-CT", + "value": "42984000" }, { - "type": "ICPC2", - "value": "R24" + "type": "PIH", + "value": "6029" }, { - "type": "IMO-ProblemIT", - "value": "27441" + "type": "3BT", + "value": "10063085" }, { - "type": "AMPATH", - "value": "6172" + "type": "ICPC2", + "value": "A09" }, { "type": "SNOMED-CT", - "value": "66857006" + "value": "42984000" }, - { - "type": "AMPATH", - "value": "967" - } - ] - }, - { - "concept": "133027AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Night sweats", - "conceptMappings": [ { "type": "ICPC2", "value": "A09" }, + { + "type": "IMO-ProblemIT", + "value": "50760" + }, { "type": "ICD-10-WHO", "value": "R61.1" @@ -1297,8 +1426,8 @@ "value": "6029" }, { - "type": "SNOMED-CT", - "value": "42984000" + "type": "AMPATH", + "value": "6029" }, { "type": "PIH", @@ -1313,6 +1442,52 @@ "value": "10063085" } ] + }, + { + "concept": "1107AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "None", + "conceptMappings": [ + { + "type": "org.openmrs.module.mdrtb", + "value": "NONE" + }, + { + "type": "PIH-Malawi", + "value": "1107" + }, + { + "type": "PIH", + "value": "1107" + }, + { + "type": "SNOMED-CT", + "value": "260413007" + }, + { + "type": "org.openmrs.module.mdrtb", + "value": "NONE" + }, + { + "type": "AMPATH", + "value": "1107" + }, + { + "type": "SNOMED-CT", + "value": "260413007" + }, + { + "type": "PIH-Malawi", + "value": "1107" + }, + { + "type": "PIH", + "value": "1107" + }, + { + "type": "AMPATH", + "value": "1107" + } + ] } ] }, @@ -1339,24 +1514,207 @@ "concept": "c4f81292-61a3-4561-a4ae-78be7d16d928", "answers": [ { - "concept": "d8e46cc0-4d08-45d9-a46d-bd083db63057", - "label": "Scrotal swelling and pain (Male)", - "conceptMappings": [] + "concept": "118990AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Genital Sore", + "conceptMappings": [ + { + "type": "ICD-10-WHO", + "value": "N50.8" + }, + { + "type": "CIEL", + "value": "118990" + }, + { + "type": "IMO-ProblemIT", + "value": "300420" + }, + { + "type": "ICD-10-WHO", + "value": "N94.8" + }, + { + "type": "CIEL", + "value": "118990" + }, + { + "type": "IMO-ProblemIT", + "value": "300420" + } + ] }, { - "concept": "60817acb-90f1-4d46-be87-2c47e150770b", - "label": "Urethral discharge/burning when urinating", - "conceptMappings": [] + "concept": "157544AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Lower abdominal pain", + "conceptMappings": [ + { + "type": "IMO-ProblemIT", + "value": "711325" + }, + { + "type": "ICD-10-WHO", + "value": "R10.3" + }, + { + "type": "CIEL", + "value": "157544" + }, + { + "type": "SNOMED-CT", + "value": "54586004" + }, + { + "type": "IMO-ProblemIT", + "value": "711325" + }, + { + "type": "ICD-10-WHO", + "value": "R10.3" + }, + { + "type": "CIEL", + "value": "157544" + }, + { + "type": "SNOMED-CT", + "value": "54586004" + } + ] + }, + { + "concept": "113122AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Scrotal Mass", + "conceptMappings": [ + { + "type": "IMO-ProblemIT", + "value": "12350" + }, + { + "type": "SNOMED-CT", + "value": "53929009" + }, + { + "type": "CIEL", + "value": "113122" + }, + { + "type": "SNOMED-CT", + "value": "53929009" + }, + { + "type": "IMO-ProblemIT", + "value": "12350" + }, + { + "type": "ICD-10-WHO", + "value": "N50.8" + }, + { + "type": "CIEL", + "value": "113122" + } + ] + }, + { + "concept": "123396AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Vaginal discharge", + "conceptMappings": [ + { + "type": "IMO-ProblemIT", + "value": "27625" + }, + { + "type": "AMPATH", + "value": "5993" + }, + { + "type": "SNOMED-CT", + "value": "271939006" + }, + { + "type": "ICD-10-WHO", + "value": "N89.8" + }, + { + "type": "ICPC2", + "value": "X14" + }, + { + "type": "IMO-ProblemIT", + "value": "32928273" + }, + { + "type": "CIEL", + "value": "123396" + }, + { + "type": "AMPATH", + "value": "5993" + }, + { + "type": "IMO-ProblemIT", + "value": "27625" + }, + { + "type": "3BT", + "value": "10102961" + }, + { + "type": "3BT", + "value": "10102961" + }, + { + "type": "IMO-ProblemIT", + "value": "32928273" + }, + { + "type": "IMO-ProblemIT", + "value": "21649296" + }, + { + "type": "SNOMED-CT", + "value": "271939006" + }, + { + "type": "CIEL", + "value": "123396" + }, + { + "type": "IMO-ProblemIT", + "value": "21649296" + } + ] }, { - "concept": "06be8996-ef55-438b-bbb9-5bebeb18e779", - "label": "Lower abdominal pain +/- vaginal discharge (Female)", + "concept": "c795654c-bcd8-4074-9fc7-e5f762e58f36", + "label": "Urethral Discharge", "conceptMappings": [] }, { - "concept": "faf06026-fce9-4d2c-9ef2-24fb45343804", - "label": "Genital sores/swollen inguinal lymph nodes with or without pain", - "conceptMappings": [] + "concept": "1115AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Normal", + "conceptMappings": [ + { + "type": "AMPATH", + "value": "1115" + }, + { + "type": "AMPATH", + "value": "1115" + }, + { + "type": "CIEL", + "value": "1115" + }, + { + "type": "SNOMED-CT", + "value": "17621005" + }, + { + "type": "SNOMED-CT", + "value": "17621005" + } + ] } ] }, @@ -1365,21 +1723,22 @@ "intent": "*", "required": "true", "unspecified": "true" - }, - { - "intent": "HTS_HIVTEST", - "required": "true", - "unspecified": "true" - }, - { - "intent": "*", - "required": "false" } ], "id": "stiSymptoms" } ] } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "false", + "hide": { + "hideWhenExpression": "isEmpty(preTestCounselingConsent) || preTestCounselingConsent !== '488b58ff-64f5-4f8a-8979-fa79940b1594' || preTestCounsellingConducted !== '488b58ff-64f5-4f8a-8979-fa79940b1594'" + } + } ] }, { @@ -1448,7 +1807,7 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "hivTestConducted !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" + "hideWhenExpression": "isEmpty(hivTestConducted) || hivTestConducted !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" }, "validators": [ { @@ -1457,7 +1816,7 @@ }, { "type": "js_expression", - "failsWhenExpression": "isDateBefore(myValue, '1980-01-01') || myValue > today()" + "failsWhenExpression": "isDateBefore(myValue, '1980-01-01') || myValue >= today()" } ] } @@ -1503,10 +1862,7 @@ { "intent": "*", "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "hivTestConducted !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" - } + "unspecified": "true" } ], "id": "firstHivTestRDT" @@ -1559,7 +1915,10 @@ { "intent": "*", "required": "true", - "unspecified": "true" + "unspecified": "true", + "hide": { + "hideWhenExpression": "hivTestConducted !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" + } } ], "id": "firstHivTestRDTResult" @@ -1614,12 +1973,22 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "firstHivTestRDT !== '166453AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + "hideWhenExpression": "isEmpty(firstHivTestRDT) || firstHivTestRDT !== '166453AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" } } ], "id": "syphilisResult" } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "hivTestConducted !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" + } + } ] }, { @@ -1683,10 +2052,7 @@ { "intent": "*", "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "firstHivTestRDTResult !== '6378487b-584d-4422-a6a6-56c8830873ff'" - } + "unspecified": "true" } ], "id": "secondHivTestDone" @@ -1727,7 +2093,7 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "secondHivTestDone !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + "hideWhenExpression": "isEmpty(secondHivTestDone) || secondHivTestDone !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" } } ] @@ -1780,7 +2146,10 @@ { "intent": "*", "required": "true", - "unspecified": "true" + "unspecified": "true", + "hide": { + "hideWhenExpression": "isEmpty(secondHivTestDone) || secondHivTestDone !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } } ], "id": "secondHivTestResult" @@ -1824,11 +2193,21 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "firstHivTestRDTResult === '6378487b-584d-4422-a6a6-56c8830873ff' && secondHivTestDone === '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' && secondHivTestResult === '6378487b-584d-4422-a6a6-56c8830873ff'" + "hideWhenExpression": "isEmpty(secondHivTestDone) || secondHivTestDone !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" } } ] } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "isEmpty(firstHivTestRDTResult) || firstHivTestRDTResult !== '6378487b-584d-4422-a6a6-56c8830873ff'" + } + } ] }, { @@ -1893,10 +2272,7 @@ { "intent": "*", "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "intermediateA1andA2HivResults !== '6378487b-584d-4422-a6a6-56c8830873ff'" - } + "unspecified": "true" } ] }, @@ -1935,7 +2311,7 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "firstHivTestRDTRepeatDone !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + "hideWhenExpression": "firstHivTestRDTRepeatDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || thirdHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" } } ], @@ -1991,12 +2367,22 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "firstHivTestRDTRepeatDone !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + "hideWhenExpression": "firstHivTestRDTRepeatDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || thirdHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" } } ], "id": "firstHivTestRepeatResult" } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "isEmpty(intermediateA1andA2HivResults) || intermediateA1andA2HivResults !== '1138AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || secondHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } ] }, { @@ -2060,10 +2446,7 @@ { "intent": "*", "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "firstHivTestRDTResult !== '6378487b-584d-4422-a6a6-56c8830873ff'" - } + "unspecified": "true" } ], "id": "thirdHivTestDone" @@ -2103,7 +2486,7 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "thirdHivTestDone !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + "hideWhenExpression": "isEmpty(thirdHivTestDone) || thirdHivTestDone !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" } } ], @@ -2159,12 +2542,103 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "thirdHivTestDone !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + "hideWhenExpression": "isEmpty(thirdHivTestDone) || thirdHivTestDone !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" } } ], "id": "thirdHivTestResult" } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "isEmpty(intermediateA1andA2HivResults) || intermediateA1andA2HivResults !== '6378487b-584d-4422-a6a6-56c8830873ff' || secondHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || firstHivTestRDTRepeatDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || thirdHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } + ] + }, + { + "label": "HIV Testing Status", + "isExpanded": "false", + "questions": [ + { + "label": "State of testing algorithm", + "type": "obs", + "questionOptions": { + "rendering": "checkbox", + "concept": "ec8b1fb4-fad1-47ae-859e-b70ecb8c5533", + "answers": [ + { + "concept": "1267AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Completed", + "conceptMappings": [ + { + "type": "SNOMED-CT", + "value": "255594003" + }, + { + "type": "CIEL", + "value": "1267" + }, + { + "type": "AMPATH", + "value": "1267" + } + ] + }, + { + "concept": "163339AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Incomplete", + "conceptMappings": [] + }, + { + "concept": "1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "label": "Not done", + "conceptMappings": [ + { + "type": "CIEL", + "value": "1118" + }, + { + "type": "PIH", + "value": "2475" + }, + { + "type": "AMPATH", + "value": "1118" + }, + { + "type": "SNOMED-CT", + "value": "385660001" + }, + { + "type": "SNOMED-CT", + "value": "385660001" + }, + { + "type": "AMPATH", + "value": "1118" + }, + { + "type": "PIH", + "value": "1118" + } + ] + } + ] + }, + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true" + } + ], + "id": "statusTestingAlgorithm" + } ] }, { @@ -2224,16 +2698,7 @@ { "intent": "*", "required": "true", - "unspecified": "true", - "hide": { - "hideWhenExpression": "hivTestConducted !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" - }, - "validators": [ - { - "type": "js_expression", - "failsWhenExpression": "(initialHIVTestResult === '6378487b-584d-4422-a6a6-56c8830873ff' && confirmatoryHIVTestResult === '6378487b-584d-4422-a6a6-56c8830873ff' && myValue !== '6378487b-584d-4422-a6a6-56c8830873ff') || (initialHIVTestResult === '664AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' && myValue !== '664AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA') || (isEmpty(tieBreakerTestResult) && initialHIVTestResult === '6378487b-584d-4422-a6a6-56c8830873ff' && confirmatoryHIVTestResult !== '6378487b-584d-4422-a6a6-56c8830873ff' && myValue !== '7398c91a-8db8-480d-8130-1a92cc208ded') || (!isEmpty(tieBreakerTestResult) && myValue !== tieBreakerTestResult)" - } - ] + "unspecified": "true" } ], "id": "finalHIVTestResult" @@ -2335,6 +2800,16 @@ ], "id": "hiVTestResultsReceivedDate" } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "false", + "hide": { + "hideWhenExpression": "secondHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || firstHivTestRDTRepeatDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || thirdHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } ] }, { @@ -2405,7 +2880,7 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "receivedHIVTestResult !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || counselingSessionType !== '09472f39-6030-4f71-a8f2-30b2fdc734ed'" + "hideWhenExpression": "isEmpty(receivedHIVTestResult) || receivedHIVTestResult !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || counselingSessionType !== '09472f39-6030-4f71-a8f2-30b2fdc734ed'" } } ], @@ -2441,14 +2916,34 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "resultReceivedCouple !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + "hideWhenExpression": "isEmpty(resultReceivedCouple) || resultReceivedCouple !== '1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" } } ], "id": "CoupleResults" } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "isEmpty(counselingSessionType) || counselingSessionType !== '09472f39-6030-4f71-a8f2-30b2fdc734ed' || secondHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || firstHivTestRDTRepeatDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || thirdHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } ] } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "false", + "hide": { + "hideWhenExpression": "preTestCounselingConsent === '488b58ff-64f5-4f8a-8979-fa79940b1594' || preTestCounsellingConducted === '488b58ff-64f5-4f8a-8979-fa79940b1594'" + } + } ] }, { @@ -2466,12 +2961,31 @@ "concept": "976ca997-fb2b-4bef-a299-f7c9e16b50a8", "answers": [ { + "concept": "cf82933b-3f3f-45e7-a5ab-5d31aaee3da3", "label": "Yes", - "concept": "cf82933b-3f3f-45e7-a5ab-5d31aaee3da3" + "conceptMappings": [ + { + "type": "CIEL", + "value": "1065" + }, + { + "type": "AMPATH", + "value": "1065" + }, + { + "type": "PIH", + "value": "1065" + }, + { + "type": "SNOMED CT", + "value": "CT: 373066001" + } + ] }, { + "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594", "label": "No", - "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594" + "conceptMappings": [] } ] }, @@ -2485,7 +2999,7 @@ "id": "recencyTestingConsent" }, { - "label": "Recency conducted", + "label": "Recency test conducted", "type": "obs", "questionOptions": { "rendering": "radio", @@ -2524,7 +3038,10 @@ { "intent": "*", "required": "true", - "unspecified": "true" + "unspecified": "true", + "hide": { + "hideWhenExpression": "isEmpty(recencyTestingConsent) || recencyTestingConsent !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" + } } ], "id": "recencyTestConducted" @@ -2596,14 +3113,34 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "recencyTestConducted !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" + "hideWhenExpression": "isEmpty(recencyTestConducted) || recencyTestConducted !== 'cf82933b-3f3f-45e7-a5ab-5d31aaee3da3'" } } ], "id": "recencyTestResult" } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "isEmpty(finalHIVTestResult) || finalHIVTestResult !== '6378487b-584d-4422-a6a6-56c8830873ff'" + } + } ] } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "false", + "hide": { + "hideWhenExpression": "finalHIVTestResult !== '6378487b-584d-4422-a6a6-56c8830873ff' || preTestCounselingConsent === '488b58ff-64f5-4f8a-8979-fa79940b1594' || preTestCounsellingConducted === '488b58ff-64f5-4f8a-8979-fa79940b1594' || secondHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || firstHivTestRDTRepeatDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || thirdHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } ] }, { @@ -2631,7 +3168,7 @@ ], "answers": [ { - "concept": "1065AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "concept": "cf82933b-3f3f-45e7-a5ab-5d31aaee3da3", "label": "Yes", "conceptMappings": [ { @@ -2648,53 +3185,14 @@ }, { "type": "SNOMED CT", - "value": "373066001" + "value": "CT: 373066001" } ] }, { - "concept": "1066AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "concept": "488b58ff-64f5-4f8a-8979-fa79940b1594", "label": "No", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1066" - }, - { - "type": "AMPATH", - "value": "1066" - }, - { - "type": "PIH", - "value": "1066" - }, - { - "type": "SNOMED-CT", - "value": "373067005" - } - ] - }, - { - "concept": "1067AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", - "label": "Unknown", - "conceptMappings": [ - { - "type": "CIEL", - "value": "1067" - }, - { - "type": "AMPATH", - "value": "1067" - }, - { - "type": "PIH", - "value": "1067" - }, - { - "type": "SNOMED CT", - "value": "261665006" - } - ] + "conceptMappings": [] } ] }, @@ -3098,12 +3596,41 @@ "required": "true", "unspecified": "true", "hide": { - "hideWhenExpression": "linkedToCare !== '488b58ff-64f5-4f8a-8979-fa79940b1594'" + "hideWhenExpression": "isEmpty(linkedToCare) || linkedToCare !== '488b58ff-64f5-4f8a-8979-fa79940b1594'" } } ], "id": "patientIdentificationNumber" }, + { + "label": "Facility Linked to", + "type": "obs", + "questionOptions": { + "rendering": "text", + "concept": "161562AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA", + "conceptMappings": [ + { + "type": "CIEL", + "value": "161562" + }, + { + "type": "CIEL", + "value": "161562" + } + ] + }, + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "true", + "hide": { + "hideWhenExpression": "isEmpty(linkedToCare) || linkedToCare !== '488b58ff-64f5-4f8a-8979-fa79940b1594'" + } + } + ], + "id": "facilityLinkedTo" + }, { "label": "HTS provider’s name", "type": "obs", @@ -3128,6 +3655,16 @@ } ] } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "false", + "hide": { + "hideWhenExpression": "preTestCounselingConsent === '488b58ff-64f5-4f8a-8979-fa79940b1594' || preTestCounsellingConducted === '488b58ff-64f5-4f8a-8979-fa79940b1594' || secondHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || firstHivTestRDTRepeatDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || thirdHivTestDone === '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } ] }, { @@ -3156,6 +3693,16 @@ } ] } + ], + "behaviours": [ + { + "intent": "*", + "required": "true", + "unspecified": "false", + "hide": { + "hideWhenExpression": "preTestCounselingConsent !== '488b58ff-64f5-4f8a-8979-fa79940b1594' || preTestCounsellingConducted !== '488b58ff-64f5-4f8a-8979-fa79940b1594' || secondHivTestDone !== '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || firstHivTestRDTRepeatDone !== '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' || thirdHivTestDone !== '1118AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'" + } + } ] } ],