Helllo, I am trying to send a list of Objects from spring controller and using that list in javascript from jsp in order to make a chart. Since javascript is taking the list as a string, can anyone suggest me a proper method of doing this. Im trying to use this list to iterate in order to put values for a chart...
List list=WebKinmelServiceManager.select("select i From Item i", Item.class);\
mav.addObject("list", list);
and i want to display in jsp page inside javascript in this format..
$scope.data = {
series: ['Sales', 'Income', 'Expense'],
data : [{
x : "Jack",
y: [100,210, 384],
tooltip:"this is tooltip"
},
{
x : "John",
y: [300, 289, 456]
},
{
x : "Stacy",
y: [351, 170, 255]
},
{
x : "Luke",
y: [54, 341, 879]
}]
}
Would really appreciate :)