diff options
| author | Julien Castiaux <juc@odoo.com> | 2019-07-25 09:14:45 +0000 |
|---|---|---|
| committer | Julien Castiaux <juc@odoo.com> | 2019-07-25 09:14:45 +0000 |
| commit | 6d9dabd5d933c5cd6ba5a42103894d731a5689a0 (patch) | |
| tree | d8b7564535625aa509d06a3f391ae14e768f6aa5 | |
| parent | 6e759184d66e7f364a635331bcc50d623733ecf1 (diff) | |
[FIX] web: hide dashboard tooltip on page change
Go to CRM/Sales/Team Pileline. Place your cursor on the chart, a tooltip
appears, move your cusror away, the tooltip disappear. Now clic anywhere
on the interface so the page change (i.e. on "x Open Opportunities") and
quickly while the page loads place your cursor on the tooltip, it
appears but when the page change it doesn't disappear.
The problem here is that the graph element is removed from the DOM which
prevent the correct handling of the `mousehover` event used internally
by nv.d3 to show/hide the related tooltip.
The solution is to manually hide the tooltip when the graph element is
removed from the DOM.
opw-2042286
closes odoo/odoo#35172
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
| -rw-r--r-- | addons/web/static/src/js/fields/basic_fields.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/addons/web/static/src/js/fields/basic_fields.js b/addons/web/static/src/js/fields/basic_fields.js index 57f7e705939..fa27ad11ab3 100644 --- a/addons/web/static/src/js/fields/basic_fields.js +++ b/addons/web/static/src/js/fields/basic_fields.js @@ -2530,6 +2530,7 @@ var JournalDashboardGraph = AbstractField.extend({ * Called when the field is detached from the DOM. */ on_detach_callback: function () { + this.chart.tooltip.hidden(true); this._isInDOM = false; }, |
