Skip to content

Commit

Permalink
Changes card #37
Browse files Browse the repository at this point in the history
  • Loading branch information
nupoorkhandelwal committed Jun 11, 2021
1 parent 9911995 commit df816f2
Show file tree
Hide file tree
Showing 6 changed files with 566 additions and 329 deletions.
25 changes: 19 additions & 6 deletions child/enrolmentAdditions.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@
"comment": "Any disabilities"
},
"displayOrder": 15,
"mandatory": true
"mandatory": true,
"voided": true
},
{
"name": "Please select the disabilities",
Expand All @@ -78,6 +79,17 @@
"displayOrder": 16,
"mandatory": true
},
{
"name": "Specify other disability",
"uuid": "461d4dac-d879-4c16-9e5b-fba44588e8e2",
"keyValues": [],
"concept": {
"uuid": "88a6bcbb-90b8-4ecb-8dfa-62ad871e3621",
"comment": "Other disability"
},
"displayOrder": 16.2,
"mandatory": true
},
{
"name": "Any chronic illness?",
"uuid": "27610477-b706-414d-9a3e-4ad5a6af50ff",
Expand All @@ -92,13 +104,13 @@
},
{
"name": "Chronic illness",
"uuid": "6f8de0cc-2cf5-4873-8f41-96cf6b8f0445",
"uuid": "bb0710a7-887c-4eea-a4c8-2c538a40ded3",
"keyValues": [],
"concept": {
"uuid": "989a09cf-a570-4ea9-ac67-422da92afce1",
"comment": "Other Chronic Illness"
"uuid": "ee71d898-53aa-4acb-943e-ecc1b16e6a6c",
"name": "Name of Disease"
},
"displayOrder": 18,
"displayOrder": 18.5,
"mandatory": true
},
{
Expand All @@ -110,7 +122,8 @@
"comment": "Day of month for growth monitoring visit"
},
"displayOrder": 19,
"mandatory": true
"mandatory": true,
"voided": true
}
]
}
Expand Down
17 changes: 17 additions & 0 deletions child/enrolmentConcepts.json
Original file line number Diff line number Diff line change
Expand Up @@ -536,6 +536,16 @@
"name": "Other Chronic Illness",
"dataType": "Text"
},
{
"uuid": "88a6bcbb-90b8-4ecb-8dfa-62ad871e3621",
"name": "Other disability",
"dataType": "Text"
},
{
"uuid": "ee71d898-53aa-4acb-943e-ecc1b16e6a6c",
"name": "Name of Disease",
"dataType": "Text"
},
{
"name": "Day of month for growth monitoring visit",
"uuid": "8c607c63-25fb-4af1-984e-37dd1bae653d",
Expand Down Expand Up @@ -845,7 +855,14 @@
"name": "Other",
"uuid": "05ea583c-51d2-412d-ad00-06c432ffe538",
"order": 4.0
},
{
"name": "None",
"uuid": "ebda5e05-a995-43ca-ad1a-30af3b937539",
"unique": true,
"order": 5.0
}

]
},
{
Expand Down
10 changes: 8 additions & 2 deletions child/rules/enrolmentHandler.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,15 @@ class ChildEnrolmentHandlerJSS {
.getFormElementsStatusesWithoutDefaults(new ChildEnrolmentHandlerJSS(), programEnrolment, formElementGroup);
}

pleaseSelectTheDisabilities(programEnrolment, formElement) {
// pleaseSelectTheDisabilities(programEnrolment, formElement) {
// const statusBuilder = this._getStatusBuilder(programEnrolment, formElement);
// statusBuilder.show().when.valueInEnrolment("Is there any developmental delay or disability seen?").containsAnswerConceptName("Yes");
// return statusBuilder.build();
// }

specifyOtherDisability(programEnrolment, formElement) {
const statusBuilder = this._getStatusBuilder(programEnrolment, formElement);
statusBuilder.show().when.valueInEnrolment("Is there any developmental delay or disability seen?").containsAnswerConceptName("Yes");
statusBuilder.show().when.valueInEnrolment("Child Disabilities").containsAnswerConceptName("Other");
return statusBuilder.build();
}

Expand Down
22 changes: 22 additions & 0 deletions create_view.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
set role jss;
drop view if exists jss_wfa_grade_view;
create view jss_wfa_grade_view(grade) as
(select 'Normal'
union
select 'Moderately Underweight'
union
select 'Severely Underweight');

set role jss;
drop view if exists jss_catchment_filter;
create view jss_catchment_filter(name) as
(select id, name
from catchment
where name not like 'JSS Master Catchment');

set role jss;
drop view if exists jss_phulwari_filter;
create view jss_phulwari_filter(name) as
(select answer_concept_name as name
from concept_concept_answer
where concept_name like 'Phulwari');
Loading

0 comments on commit df816f2

Please sign in to comment.