diff options
| author | Gery Debongnie <ged@openerp.com> | 2013-11-23 11:11:35 +0100 |
|---|---|---|
| committer | Gery Debongnie <ged@openerp.com> | 2013-11-23 11:11:35 +0100 |
| commit | 1e32b763f0e1da669d835b02fbf680f2deea0f65 (patch) | |
| tree | 1189f26ec2f52e12a83ac0bf611dbbc1498e873f /addons/web_graph/static/src/js/graph.js | |
| parent | 7299cde4cf2063dbccc797b6612c2b41c3564a8e (diff) | |
[IMP] add 'clear all groups' and 'swap axis' functionality to pivot table in addon web_graph
bzr revid: ged@openerp.com-20131123101135-m0cx5eg0o41k7x2m
Diffstat (limited to 'addons/web_graph/static/src/js/graph.js')
| -rw-r--r-- | addons/web_graph/static/src/js/graph.js | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/addons/web_graph/static/src/js/graph.js b/addons/web_graph/static/src/js/graph.js index cfabdead833..da3f4257b33 100644 --- a/addons/web_graph/static/src/js/graph.js +++ b/addons/web_graph/static/src/js/graph.js @@ -57,6 +57,16 @@ instance.web_graph.GraphView = instance.web.View.extend({ .then(this.proxy('draw_table')); } }, + + 'click label.graph_swap_axis' : function (event) { + this.pivot_table.swap_axis(); + this.draw_table(); + }, + + 'click label.graph_clear_all' : function (event) { + this.pivot_table.clear_all(); + this.draw_table(); + }, }, view_loading: function (fields_view_get) { @@ -212,7 +222,6 @@ instance.web_graph.GraphView = instance.web.View.extend({ }, draw_table: function () { - console.log("cols",this.pivot_table.cols); this.table.empty(); this.draw_top_headers(); _.each(this.pivot_table.rows, this.proxy('draw_row')); |
