function drawPersonTable(){ var strOut = ""; for( var i = 0; i < objPersonArray.length; i++ ){ strOut += ""; strOut += ""; strOut += ""; strOut += ""; strOut += ""; // keeps track of whether the profile has non-medication based problems selected. var hasNonMedicationSelection = false; var healthStat = ""; if (objPersonArray[i].numHealthLevel == 0) { healthStat = "Generally Well"; } else if (objPersonArray[i].numHealthLevel == 1) { hasNonMedicationSelection = true healthStat = "Some Health Needs"; } else if (objPersonArray[i].numHealthLevel == 2) { hasNonMedicationSelection = true healthStat = "Significant Needs"; } strOut += ""; var conditions = ""; var conditionCounter = 0; if (objPersonArray[i].con0 == "true") { hasNonMedicationSelection = true conditions += "Asthma
"; conditionCounter++; } if (objPersonArray[i].con1 == "true") { hasNonMedicationSelection = true conditions += "Cancer
"; conditionCounter++; } if (objPersonArray[i].con2 == "true") { hasNonMedicationSelection = true conditions += "Diabetes
"; conditionCounter++; } if (objPersonArray[i].con3 == "true") { hasNonMedicationSelection = true conditions += "Heart Disease
"; conditionCounter++; } if (objPersonArray[i].con4 == "true") { hasNonMedicationSelection = true conditions += "High Blood Pressure
"; conditionCounter++; } if (objPersonArray[i].con5 == "true") { hasNonMedicationSelection = true conditions += "Mental Health Conditions
"; conditionCounter++; } if (objPersonArray[i].con6 == "true") { hasNonMedicationSelection = true conditions += "Pregnancy/Expecting to deliver
a child in the next year
"; conditionCounter++; } if (objPersonArray[i].con7 == "true") { hasNonMedicationSelection = true conditions += "Sinusitis/Rhinitis
"; conditionCounter++; } if (conditionCounter == 0) { conditions += "None
"; } var medStat = ""; if (objPersonArray[i].d0 == "true") { medStat += "Group A
"; } if (objPersonArray[i].d1 == "true") { medStat += "Group B
"; } if (objPersonArray[i].d2 == "true") { medStat += "Group C
"; } if (objPersonArray[i].d3 == "true") { medStat += "Group D
"; } if (medStat == "") { if (hasNonMedicationSelection) { medStat += "No additional medications"; } else { medStat += "No medications"; } } strOut += ""; //strOut += ""; strOut += ""; if( i == 0 ){ strOut += ""; }else{ strOut += ""; } strOut += ""; } document.getElementById("peopleHolderMini").innerHTML = strOut; }
        AgeSexHealth StatusMedicationsConditionsDelete
" + getMiniPersonBackground(i) + "" + objPersonArray[i].strName + " " + objPersonArray[i].strAge + " "; if (objPersonArray[i].numSex == 1) { strOut += "Female"; } if (objPersonArray[i].numSex == 2) { strOut += "Male"; } strOut += ""+healthStat+" "+medStat+" " + objPersonArray[i].Conditions + " " + conditions + "