From e7f1d2176eecde2e561bdfa99b168e27857e2e01 Mon Sep 17 00:00:00 2001 From: Coleman Watts Date: Mon, 9 Jun 2014 14:51:00 +0100 Subject: [PATCH] CRM-14690 - Target correct button for undo action --- js/crm.ajax.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/crm.ajax.js b/js/crm.ajax.js index 2968acb308..0fd7f4b303 100644 --- a/js/crm.ajax.js +++ b/js/crm.ajax.js @@ -355,7 +355,7 @@ } if (widget.data('uiDialog')) { // This is a bit harsh but we are removing jQuery UI's event handler from the close button and adding our own - $('.ui-dialog-titlebar-close').first().off().click(cancelAction); + widget.parent().find('.ui-dialog-titlebar-close').first().off().click(cancelAction); } widget.on('crmFormLoad.crmForm', function(event, data) { -- 2.25.1