Alex GG
Posts: 0
Joined: Thu Nov 14, 2013 11:11 pm

graph a pie chart using variable names (jqplot)

hello Igor.
the link you gave me, doesn ́t help me at all. I ́d try to explain again:
this is my data mapping using DB of above:
Image
I use "where" in the request with this : return '{"servicio":"bb"}';
and in the result page I get these two values (cantidad) in labels: Image

what I need is a JS to get the total of those values. let say 600+400 = 1000.
thanks!!

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

graph a pie chart using variable names (jqplot)

Hello! You can calculate sum of elements on service Success event: prevar sum = 0;
data.forEach(function(el){ sum+= +el['cantidad']});
alert(sum);/pre

Alex GG
Posts: 0
Joined: Thu Nov 14, 2013 11:11 pm

graph a pie chart using variable names (jqplot)

great!!! thanks Maryna =)

Return to “Issues”