diff options
Diffstat (limited to 'addons/web/static/src')
| -rw-r--r-- | addons/web/static/src/js/views/graph_widget.js | 11 | ||||
| -rw-r--r-- | addons/web/static/src/js/views/list_view.js | 7 | ||||
| -rw-r--r-- | addons/web/static/src/less/graph_view.less | 6 |
3 files changed, 19 insertions, 5 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); diff --git a/addons/web/static/src/js/views/list_view.js b/addons/web/static/src/js/views/list_view.js index e97b4eac93f..e43e8acdfd6 100644 --- a/addons/web/static/src/js/views/list_view.js +++ b/addons/web/static/src/js/views/list_view.js @@ -554,8 +554,11 @@ var ListView = View.extend({ if (self.display_nocontent_helper()) { self.no_result(); } else { - // Load previous page if the current one is empty - if (self.records.length === 0 && self.dataset.size() > 0) { + if (self.records.length && self.current_min === 1) { + // Reload the list view if we delete all the records of the first page + self.reload(); + } else if (self.records.length && self.dataset.size() > 0) { + // Load previous page if the current one is empty self.pager.previous(); } // Reload the list view if we are not on the last page diff --git a/addons/web/static/src/less/graph_view.less b/addons/web/static/src/less/graph_view.less index c0d460ab3f1..f77b4faa9d0 100644 --- a/addons/web/static/src/less/graph_view.less +++ b/addons/web/static/src/less/graph_view.less @@ -10,9 +10,13 @@ } } +.nvtooltip thead { + background-color: transparent; +} + // ------------------------------------------------------------------ // Control panel buttons // ------------------------------------------------------------------ .o_graph_measures_list { .o-selected-li; -}
\ No newline at end of file +} |
