From ee51d082c8fb099bbea65fbad042427f21ca0f7b Mon Sep 17 00:00:00 2001 From: Astik Singh <assi@odoo.com> Date: Fri, 11 Aug 2023 15:58:54 +0530 Subject: [PATCH] [FIX] survey: resolved the popover issue stuck in a live session Before this commit: In the survey, when you start a live session and click on the URL the `copied` popover appears but doesn't go away. After this commit: Now that popover will close automatically. Reason: There was already a `tooltip` instance on the element and we try to add the `popover` on that element which causes an issue. Task- 3458901 closes odoo/odoo#132956 Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com> --- addons/survey/static/src/js/survey_session_manage.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/addons/survey/static/src/js/survey_session_manage.js b/addons/survey/static/src/js/survey_session_manage.js index 4f0b43b48b49..a5d427abebb4 100644 --- a/addons/survey/static/src/js/survey_session_manage.js +++ b/addons/survey/static/src/js/survey_session_manage.js @@ -87,6 +87,7 @@ publicWidget.registry.SurveySessionManage = publicWidget.Widget.extend(SurveyPre ev.preventDefault(); var $clipboardBtn = this.$('.o_survey_session_copy'); + $clipboardBtn.tooltip('dispose'); $clipboardBtn.popover({ placement: 'right', @@ -108,7 +109,7 @@ publicWidget.registry.SurveySessionManage = publicWidget.Widget.extend(SurveyPre clipboard.destroy(); $clipboardBtn.popover('show'); _.delay(function () { - $clipboardBtn.popover('hide'); + $clipboardBtn.popover('dispose'); }, 800); }); -- GitLab