Assessment Checklist
Template dummy data for configure rules-
{
"checklistConfig": [
{
"tabType": "referral",
"rulesConfig": [
{
"ruleNumber": 1,
"conditions": [
{
"code": "SN1",
"values":
"SHORTAGES"
},
{
"condition": 2,
"isRequired": true,
"code": "SN2",
"values": [
"HOSPITALS",
]
}
]
},
{
"ruleNumber": 2,
"conditions": [
{
"condition": 1,
"isRequired": true,
"code": "SN3",
"values": [
"YES"
]
},
{
"condition": 2,
"isRequired": true,
"code": "SN4",
"values": [
"YES"
]
}
]
}
]
}
]
}
Output data format
{
"checklistConfig": [
{
"tabType": "referral",
"rulesConfig": [
{
"ruleNumber": 1,
"conditions": [
{
"id": "2d4a7b1e-1f2f-4a8a-9672-43396c6c9a1c",
"condition": 1,
"isRequired": true,
"code": "Is the child administered for the first time?",
"values": [
"YES",
"NO",
"NOTSELECTED"
],
"answer": [
"YES"
]
},
{
"id": "2d4a7b1e-1f2f-4a8a-9672-43396c6c9a1c",
"condition": 1,
"isRequired": true,
"code": "Is the child administered for the second time?",
"values": [
"YES",
"NO",
"NOTSELECTED"
],
"answer": [
"NO"
]
}
]
},
{
"ruleNumber": 2,
"conditions": [
{
"id": "2d4a7b1e-1f2f-4a8a-9672-43396c6c9a1c",
"condition": 1,
"isRequired": true,
"code": "Is the child sick?",
"values": [
"YES",
"NO",
"NOTSELECTED"
],
"answer": [
"NO"
]
}
]
}
]
},
{
"tabType": "delivery",
"rulesConfig": [
{
"ruleNumber": 1,
"conditions": [
{
"id": "4add5323-fc98-4e71-a783-27dbb922c99f",
"condition": 2,
"isRequired": true,
"code": "Is the child having fever?",
"values": [
"YES",
"NO",
"NOTSELECTED"
],
"answer": [
"YES"
]
}
]
},
{
"ruleNumber": 2,
"conditions": [
{
"id": "4add5323-fc98-4e71-a783-27dbb922c99f",
"condition": 2,
"parentId": null,
"isRequired": true,
"code": "Is child above 5 years?",
"values": [
"YES",
"NO",
"NOTSELECTED"
],
"answer": [
"YES"
]
}
]
}
]
}
]
}
Points logic
This will be written in the wrapper For the points assignment for the questions, we will calculate on the basis of Screen Type and/or condition AND/OR Conditions Points assigned for each referral = 100
X = 100/ no of rules
Points for each ques = x/no of conditions in each rule
Limitations
If same ques is available for one than one referral flow, then point assigned to them will be equal for more than one flow, that will cause discrepancy in the app, Possible solutions to this
1) if the points are the same for a ques for more than one flow then , we can introduce a variable for flow preference in the app, if points are same then go with the flow preference.
2) Or we can put validation from the console side , that question cannot be repeated more than once
FLOW
Data required for the api This transform of data will happen in a wrapper
{
"tenantId": "mz",
"code": "SMC Campaign.ELIGIBILITY.DISTRIBUTOR",
"isActive": true,
"additionalFields": {
"schema": "ServiceDefinition",
"version": 1,
"fields": [
{
"key": "precedenceFlow",
"value": "SMC1.YES"
},
{
"key": "flow",
"value": [
"TO_ADMINISTER",
"BENEFICIARY_REFUSED",
"BENEFICIARY_REFERRED"
]
}
]
},
"attributes": [
{
"tenantId": "mz",
"code": "Is the child administered for the first time?",
"dataType": "SingleValueList",
"values": [
"YES",
"NO",
"NOTSELECTED"
],
"isActive": true,
"required": true,
"order": 1,
"additionalFields": {
"schema": "ServiceAttribute",
"version": 1,
"fields": [
{
"key": "pointsMapping",
"value": {
"YES": {
"TO_ADMINISTER": 0,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 0
},
"NO": {
"TO_ADMINISTER": 0,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 50
},
"NOTSELECTED": {
"TO_ADMINISTER": 0,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 0
}
}
}
]
}
},
{
"tenantId": "mz",
"code": "Is the child sick?",
"dataType": "SingleValueList",
"values": [
"YES",
"NO"
],
"isActive": true,
"required": true,
"order": 2,
"additionalFields": {
"schema": "ServiceAttribute",
"version": 1,
"fields": [
{
"key": "pointsMapping",
"value": {
"YES": {
"TO_ADMINISTER": 0,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 0
},
"NO": {
"TO_ADMINISTER": 0,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 50
}
}
}
]
}
},
{
"tenantId": "mz",
"code": "Is the child having fever?",
"dataType": "SingleValueList",
"values": [
"YES",
"NO",
"NOTSELECTED"
],
"isActive": true,
"required": true,
"order": 3,
"additionalFields": {
"schema": "ServiceAttribute",
"version": 1,
"fields": [
{
"key": "pointsMapping",
"value": {
"YES": {
"TO_ADMINISTER": 50,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 0
},
"NO": {
"TO_ADMINISTER": 0,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 0
},
"NOTSELECTED": {
"TO_ADMINISTER": 0,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 0
}
}
}
]
}
},
{
"tenantId": "mz",
"code": "Is child above 5 years?",
"dataType": "SingleValueList",
"values": [
"YES",
"NO",
"NOTSELECTED"
],
"isActive": true,
"required": true,
"order": 4,
"additionalFields": {
"schema": "ServiceAttribute",
"version": 1,
"fields": [
{
"key": "pointsMapping",
"value": {
"YES": {
"TO_ADMINISTER": 50,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 0
},
"NO": {
"TO_ADMINISTER": 0,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 0
},
"NOTSELECTED": {
"TO_ADMINISTER": 0,
"BENEFICIARY_REFUSED": 0,
"BENEFICIARY_REFERRED": 0
}
}
}
]
}
}
]
}
Last updated
Was this helpful?