From e5267a0ef6ed6c651b6dbcc0fcc0a514b4e6e26e Mon Sep 17 00:00:00 2001 From: Coleman Watts Date: Fri, 14 Mar 2014 09:21:05 -0400 Subject: [PATCH] CRM-13863 - Whitelist instead of blacklist open-inline --- js/Common.js | 2 +- js/crm.livePage.js | 4 +--- js/crm.searchForm.js | 4 +--- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/js/Common.js b/js/Common.js index 1be50a619d..2f79c8e104 100644 --- a/js/Common.js +++ b/js/Common.js @@ -907,7 +907,7 @@ CRM.validate = CRM.validate || { validate: true, refreshAction: ['next_new', 'submit_savenext'], cancelButton: '.cancel.form-submit', - openInline: 'a.button:not("[href=#], .no-popup")', + openInline: 'a.open-inline, a.button:not("[href=#], .no-popup")', onCancel: function(event) {}, onError: function(data) { var $el = $(this); diff --git a/js/crm.livePage.js b/js/crm.livePage.js index dff3beff86..ea355ffb5c 100644 --- a/js/crm.livePage.js +++ b/js/crm.livePage.js @@ -12,9 +12,7 @@ cj(function($) { if (url === '#' || $(this).attr('onclick') || $(this).hasClass('no-popup')) { return; } - CRM.loadForm(url, { - openInline: 'a:not("[href=#], .no-popup")' - }).on('crmFormSuccess', function(e, data) { + CRM.loadForm(url).on('crmFormSuccess', function(e, data) { // Refresh page when form completes $('#crm-main-content-wrapper').crmSnippet('refresh'); }); diff --git a/js/crm.searchForm.js b/js/crm.searchForm.js index 289ef57d7b..181a204549 100644 --- a/js/crm.searchForm.js +++ b/js/crm.searchForm.js @@ -12,9 +12,7 @@ cj(function($) { if (url === '#' || $(this).attr('onclick') || $(this).hasClass('no-popup')) { return; } - CRM.loadForm(url, { - openInline: 'a:not("[href=#], .no-popup")' - }).on('crmFormSuccess', function (e, data) { + CRM.loadForm(url).on('crmFormSuccess', function (e, data) { // Refresh page when form completes $('#crm-main-content-wrapper').crmSnippet('refresh'); }); -- 2.25.1