From: Coleman Watts Date: Sun, 1 Mar 2015 17:02:02 +0000 (-0500) Subject: CRM.loadPage - Set dialog title for confirm dialogs X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=202559b306766a9952f97114a049e32412a12f36;p=civicrm-core.git CRM.loadPage - Set dialog title for confirm dialogs --- diff --git a/js/crm.ajax.js b/js/crm.ajax.js index 8a8e74cc49..7c22c3ddd9 100644 --- a/js/crm.ajax.js +++ b/js/crm.ajax.js @@ -311,10 +311,12 @@ // Create new dialog if (settings.dialog) { settings.dialog = CRM.utils.adjustDialogDefaults(settings.dialog); - $('
' + ts('Loading') + '...
').dialog(settings.dialog); + $('
').dialog(settings.dialog); + } + if ($(settings.target).data('uiDialog')) { $(settings.target) .on('dialogclose', function() { - if ($(this).attr('data-unsaved-changes') !== 'true') { + if (settings.dialog && $(this).attr('data-unsaved-changes') !== 'true') { $(this).crmSnippet('destroy').dialog('destroy').remove(); } })