
alpsilva
Members-
Content count
2 -
Joined
-
Last visited
About alpsilva
-
Rank
Forum Newbie
-
It worked. I'm really grateful!
- 3 replies
-
- javascrip
- fusioncharts
-
(and 2 more)
Tagged with:
-
alpsilva started following Chart loads only initialized data
-
i'm trying to process data from a query. So I create a JSON object and populate it using a loop, like so: var processedData = [{ label: "teste", value: 123 }, { label: "teste2", value: 321 }]; if (dataParse.response) { dataParse = dataParse.response; for (var aux of dataParse) { jsonAux = { label: aux.departamento, value: parseInt(aux.quantidade) } processedData.push(jsonAux); } } after the loop, the object is returned and used as chart data. As seen in the image attached, it is done without problems (For testing purposes, i initialized the object "processedData" with two test elements: "teste1" and "teste2"). But FusionChart can only load the initiliazed elements. I don't have any idea why this is happening and already tried many different ways to do this. Would be really glad if someone could be of use. Thanks in advance.
- 3 replies
-
- javascrip
- fusioncharts
-
(and 2 more)
Tagged with: