diff options
| author | Gery Debongnie <ged@openerp.com> | 2014-04-02 13:47:58 +0200 |
|---|---|---|
| committer | Gery Debongnie <ged@openerp.com> | 2014-04-02 13:47:58 +0200 |
| commit | c138b778df3055dad9e1add03deaf5b519e7581f (patch) | |
| tree | ea9a1a9694111b80f6dd4e2d056df378a33990c2 /addons/web_graph/static/src/js/pivot_table.js | |
| parent | cf87e07aeb68a938d911c1cf5653de63389cb166 (diff) | |
[FIX] correctly filters out empty groups in read_group results in the data loading code of graph view (addon web_graph)
bzr revid: ged@openerp.com-20140402114758-8qfdz8j76t2p2juo
Diffstat (limited to 'addons/web_graph/static/src/js/pivot_table.js')
| -rw-r--r-- | addons/web_graph/static/src/js/pivot_table.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/addons/web_graph/static/src/js/pivot_table.js b/addons/web_graph/static/src/js/pivot_table.js index e8a438b3fe5..824b41a6b25 100644 --- a/addons/web_graph/static/src/js/pivot_table.js +++ b/addons/web_graph/static/src/js/pivot_table.js @@ -392,7 +392,9 @@ openerp.web_graph.PivotTable = openerp.web.Class.extend({ .lazy(false) .group_by(groupbys) .then(function (groups) { - return groups.map(function (group) { + return groups.filter(function (group) { + return group.attributes.length > 0; + }).map(function (group) { var attrs = group.attributes, grouped_on = attrs.grouped_on instanceof Array ? attrs.grouped_on : [attrs.grouped_on], |
