From 51040b6d60eac7a055321b5c33481bb7c4488295 Mon Sep 17 00:00:00 2001 From: Nicolas Lempereur Date: Tue, 28 Jul 2015 11:33:02 +0200 Subject: [PATCH] [FIX] web: no edit bounce effect if bootstrap element Bootstrap bind on document to do an element, in some case the bounce effect on the edit button might cancel the bootstrap action. e.g in the crm.claim form view, the `group` tag arround a notebook element break the tab change on the notebook. opw-646012 note: in 8.0 the issue didn't happen since the tab change was done by jquery ui which happened before the bounce effect. --- addons/web/static/src/js/view_form.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 18f0df22289..e58d347feb2 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -209,7 +209,7 @@ instance.web.FormView = instance.web.View.extend(instance.web.form.FieldManagerM // Add bounce effect on button 'Edit' when click on readonly page view. this.$el.find(".oe_form_group_row,.oe_form_field,label,h1,.oe_title,.oe_notebook_page, .oe_list_content").on('click', function (e) { - if(self.get("actual_mode") == "view") { + if(self.get("actual_mode") == "view" && !$(e.target).is('[data-toggle]')) { var $button = self.options.$buttons.find(".oe_form_button_edit"); $button.openerpBounce(); e.stopPropagation();