From afc021d8df20024d4303c4415010f72b3d266741 Mon Sep 17 00:00:00 2001 From: mzd Date: Thu, 1 May 2014 20:28:45 -0400 Subject: [PATCH] CRM-14353 disable check onSubmit ---------------------------------------- * CRM-14353: Fix formNavigate to work with multiple forms & ajax https://issues.civicrm.org/jira/browse/CRM-14353 --- js/Common.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/js/Common.js b/js/Common.js index cebf87a446..ca273f8bcb 100644 --- a/js/Common.js +++ b/js/Common.js @@ -476,7 +476,12 @@ CRM.validate = CRM.validate || { if ($('.ui-dialog .modal-dialog').not(e.target).length < 1) { $('body').css({overflow: ''}); } - }); + }) + .on('submit', function(e) { + // CRM-14353 - disable changes warn when submitting the form + $(this).removeAttr('data-warn-changes'); + }) + ; window.onbeforeunload = function() { if (CRM.utils.initialValueChanged($('form[data-warn-changes]'))) { -- 2.25.1