[FIX] gives the correct data to the charts function instead of undefined (addon web_graph)

bzr revid: ged@openerp.com-20131126161415-3thwtp25wm1hvks0
This commit is contained in:
Gery Debongnie 2013-11-26 17:14:15 +01:00
parent 857b48749b
commit 99b7fa4272
1 changed files with 3 additions and 1 deletions

View File

@ -2,9 +2,11 @@
function draw_chart (mode, pivot) {
var values = _.map(pivot.rows.main.children, function (pt) {
var val = pivot.get_value(pt.id, pivot.cols.main.id);
return {x: pt.name, y: val};
return {x: pt.title, y: val};
});
console.log("values",values);
switch (mode) {
case 'bar_chart':
bar_chart(values);