mirror of
https://gitlab.com/signalytic/client-external/streamline/streamline-emr.git
synced 2026-09-12 11:11:31 +00:00
resolved conflicts
This commit is contained in:
+23
@@ -0,0 +1,23 @@
|
||||
// add child row
|
||||
function add_child_div (data) {
|
||||
var child = data.split ('_');
|
||||
var child_div = $ ('#child_data_' + child[2]);
|
||||
var table_id = 'child_details_table_' + child[2];
|
||||
var pregnancy = 'pregnancy_' + child[2];
|
||||
var count = document.getElementById (table_id).rows.length;
|
||||
var row_id = count++;
|
||||
$ (child_div)
|
||||
.append (`<tr><td><input class="form-control" id="child_name_${row_id}" name="${pregnancy}_child_name[]" type="text" "placeholder"="Happy Mukisa" /></td>
|
||||
<td style="min-width: 90px;"><select style="display: inline-block;" class="form-control" name="${pregnancy}_child_gender[]" id="${pregnancy}_child_gender_${row_id}"><option value=" " selected>-- Select --</option><option value="1">Male</option><option value="2">Female</option></select></td>
|
||||
<td><input type='number' name='${pregnancy}_child_patient_number[]' id='child_patient_number_${row_id}' class='form-control' min='0'></td>
|
||||
<td><input type='number' name='${pregnancy}_child_birth_weight[]' id='child_birth_weight_${row_id}' class='form-control' min='0' step='0.1'></td>
|
||||
<td><select style="display: inline-block;" class="form-control" name="${pregnancy}_child_immunisation_status[]" id="${pregnancy}_child_immunisation_status_${row_id}"><option value=" " selected>-- Select --</option><option value="1">Not Started</option><option value="2">Ongoing</option><option value="3">Completed</option></select></td>
|
||||
<td><textarea class="form-control" name="${pregnancy}_child_health_condition[]" rows="3" "id"="${pregnancy}_child_health_condition_${row_id}"></textarea></td>
|
||||
<td><button onclick="deleteRow(this)" class="btn btn-sm btn-rounded btn-danger" title="Delete this row" style="color: white;" type="button"><i class="fa fa-trash"></i></button></td>
|
||||
</tr>`);
|
||||
}
|
||||
|
||||
// delete child row
|
||||
function deleteRow (ele) {
|
||||
ele.parentNode.parentNode.remove ();
|
||||
}
|
||||
Vendored
Executable
Vendored
Executable
+145
@@ -0,0 +1,145 @@
|
||||
// add other medical presentations maternity admission
|
||||
document
|
||||
.getElementById ('show_other_medical_presentations_input')
|
||||
.addEventListener ('change', function () {
|
||||
var textInputContainer = document.getElementById (
|
||||
'other_medical_presentations_input'
|
||||
);
|
||||
if (this.checked) {
|
||||
textInputContainer.style.display = 'block';
|
||||
} else {
|
||||
textInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
|
||||
// add other sgbv sexual and gender based violence
|
||||
document
|
||||
.getElementById ('show_other_sgbv_risk_input')
|
||||
.addEventListener ('change', function () {
|
||||
var textInputContainer = document.getElementById ('other_sgbv_risk_input');
|
||||
if (this.checked) {
|
||||
textInputContainer.style.display = 'block';
|
||||
} else {
|
||||
textInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
|
||||
// add other pregnancy complications text box
|
||||
document
|
||||
.getElementById ('show_other_pregnancy_complications_input')
|
||||
.addEventListener ('change', function () {
|
||||
var ptextInputContainer = document.getElementById (
|
||||
'other_pregnancy_complications_input'
|
||||
);
|
||||
if (this.checked) {
|
||||
ptextInputContainer.style.display = 'block';
|
||||
} else {
|
||||
ptextInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
|
||||
// add heart physical examinatinon input
|
||||
document
|
||||
.getElementById ('show_heart_physical_examination_input')
|
||||
.addEventListener ('change', function () {
|
||||
var ptextInputContainer = document.getElementById (
|
||||
'heart_physical_examination_input'
|
||||
);
|
||||
if (this.checked) {
|
||||
ptextInputContainer.style.display = 'block';
|
||||
} else {
|
||||
ptextInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
// add other physical examinatinon input
|
||||
document
|
||||
.getElementById ('show_other_physical_examination_input')
|
||||
.addEventListener ('change', function () {
|
||||
var ptextInputContainer = document.getElementById (
|
||||
'other_physical_examination_input'
|
||||
);
|
||||
if (this.checked) {
|
||||
ptextInputContainer.style.display = 'block';
|
||||
} else {
|
||||
ptextInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
|
||||
// add other obstetric risk factors
|
||||
document
|
||||
.getElementById ('show_other_obstetric_risk_factors_input')
|
||||
.addEventListener ('change', function () {
|
||||
var ptextInputContainer = document.getElementById (
|
||||
'other_obstetric_risk_factors_input'
|
||||
);
|
||||
if (this.checked) {
|
||||
ptextInputContainer.style.display = 'block';
|
||||
} else {
|
||||
ptextInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
|
||||
// add other pelvis fracture input
|
||||
document
|
||||
.getElementById ('show_pelvis_fracture_input')
|
||||
.addEventListener ('change', function () {
|
||||
var dtextInputContainer = document.getElementById ('pelvis_fracture_input');
|
||||
if (this.checked) {
|
||||
dtextInputContainer.style.display = 'block';
|
||||
} else {
|
||||
dtextInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
|
||||
// add spine fracture input
|
||||
document
|
||||
.getElementById ('show_spine_fracture_input')
|
||||
.addEventListener ('change', function () {
|
||||
var dtextInputContainer = document.getElementById ('spine_fracture_input');
|
||||
if (this.checked) {
|
||||
dtextInputContainer.style.display = 'block';
|
||||
} else {
|
||||
dtextInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
|
||||
// add femur fracture input
|
||||
document
|
||||
.getElementById ('show_femur_fracture_input')
|
||||
.addEventListener ('change', function () {
|
||||
var dtextInputContainer = document.getElementById ('femur_fracture_input');
|
||||
if (this.checked) {
|
||||
dtextInputContainer.style.display = 'block';
|
||||
} else {
|
||||
dtextInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
// add other fractures input
|
||||
document
|
||||
.getElementById ('show_other_fracture_input')
|
||||
.addEventListener ('change', function () {
|
||||
var dtextInputContainer = document.getElementById ('other_fracture_input');
|
||||
if (this.checked) {
|
||||
dtextInputContainer.style.display = 'block';
|
||||
} else {
|
||||
dtextInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
|
||||
// blood transfusion input
|
||||
document
|
||||
.getElementById ('show_blood_transfusion_input')
|
||||
.addEventListener ('change', function () {
|
||||
var dtextInputContainer = document.getElementById (
|
||||
'blood_transfusion_input'
|
||||
);
|
||||
if (this.checked) {
|
||||
dtextInputContainer.style.display = 'block';
|
||||
} else {
|
||||
dtextInputContainer.style.display = 'none';
|
||||
}
|
||||
});
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
// family planning methods select2
|
||||
$('#family_planning_methods').select2();
|
||||
|
||||
$('#family_planning_methods').click(function(){
|
||||
if($('#family_planning_methods option:selected').length > 0) {
|
||||
$('#date_discontinued_div, #why_stop_family_planning_div').show();
|
||||
$('.date_discontinued, #why_stop_family_planning').addClass('compulsory');
|
||||
$('.date_discontinued, #why_stop_family_planning').prop('required', true);
|
||||
}
|
||||
else {
|
||||
$('#date_discontinued_div, #why_stop_family_planning_div').hide();
|
||||
$('.date_discontinued, #why_stop_family_planning').removeClass('compulsory');
|
||||
$('.date_discontinued, #why_stop_family_planning').prop('required', false);
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user