Added total number of records to page
This commit is contained in:
@@ -309,6 +309,12 @@ function doBarData(id,qid, survey, Q1=0, Q2=0, Q3=0 ) {
|
||||
});
|
||||
|
||||
console.log(bardata);
|
||||
const total = Object.values(bardata).reduce((sum, value) => sum + value, 0);
|
||||
console.log(total);
|
||||
document.getElementById("record_no").textContent = total;
|
||||
if (total < 9){
|
||||
return;
|
||||
}
|
||||
drawBar(id,bardata);
|
||||
// return data; // Should be an array like [{ value: -3, count: 2 }, ..., { value: 3, count: 5 }]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user