diff options
| author | Christophe Simonis <chs@odoo.com> | 2016-11-17 14:48:43 +0100 |
|---|---|---|
| committer | Christophe Simonis <chs@odoo.com> | 2016-11-17 14:48:43 +0100 |
| commit | 1ef4061e68a6a9f07effe5efcdbd3fb3e5054cf6 (patch) | |
| tree | 32918613ae611e9b55ec5a08904a9a649bc6fd54 /addons/web/static/src/js/views/graph_widget.js | |
| parent | d7004d7dc0859056f982052184d5500846c13716 (diff) | |
| parent | 3b2f4e244f51b37050f61629bf01e6dc38cc4817 (diff) | |
[MERGE] forward port branch saas-11 up to 3b2f4e2
Diffstat (limited to 'addons/web/static/src/js/views/graph_widget.js')
| -rw-r--r-- | addons/web/static/src/js/views/graph_widget.js | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/addons/web/static/src/js/views/graph_widget.js b/addons/web/static/src/js/views/graph_widget.js index 80a575d0505..b2cd726c95c 100644 --- a/addons/web/static/src/js/views/graph_widget.js +++ b/addons/web/static/src/js/views/graph_widget.js @@ -98,7 +98,8 @@ return Widget.extend({ "there is no active filter in the search bar."), })); } else { - this['display_' + this.mode](); + var chart = this['display_' + this.mode](); + chart.tooltip.chartContainer(this.$el[0]); } }, display_bar: function () { @@ -182,6 +183,8 @@ return Widget.extend({ chart(svg); this.to_remove = chart.update; nv.utils.onWindowResize(chart.update); + + return chart; }, display_pie: function () { var data = [], @@ -232,6 +235,8 @@ return Widget.extend({ chart(svg); this.to_remove = chart.update; nv.utils.onWindowResize(chart.update); + + return chart; }, display_line: function () { if (this.data.length < 2) { @@ -309,7 +314,9 @@ return Widget.extend({ chart(svg); this.to_remove = chart.update; - nv.utils.onWindowResize(chart.update); + nv.utils.onWindowResize(chart.update); + + return chart; }, destroy: function () { nv.utils.offWindowResize(this.to_remove); |
