CRM-13863 - Add icons to confirmation dialog buttons
authorColeman Watts <coleman@civicrm.org>
Wed, 3 Sep 2014 08:03:35 +0000 (09:03 +0100)
committerColeman Watts <coleman@civicrm.org>
Wed, 3 Sep 2014 08:03:35 +0000 (09:03 +0100)
js/Common.js
templates/CRM/common/enableDisableApi.tpl

index c28c851973b5dcd5b0d5d6772a036bf89fdf7096..f3a170df57ffdacc21d1c05d957a317ec258f094 100644 (file)
@@ -796,6 +796,7 @@ CRM.strings = CRM.strings || {};
       $.each(settings.options, function(key, label) {
         settings.buttons.push({
           text: label,
+          icons: {primary: key === 'no' ? 'ui-icon-close' : 'ui-icon-check'},
           click: function() {
             var event = $.Event('crmConfirm:' + key);
             $(this).trigger(event);
index 87a87ae62ddba0439cd0ff14645e016318f2a28b..2396685fee02f7e1532a0ae24ef045819380a17b 100644 (file)
@@ -53,8 +53,8 @@
         conf.html(response.content);
         if (!response.illegal) {
           conf.dialog('option', 'buttons', [
-            {text: {/literal}'{ts escape="js"}Yes{/ts}'{literal}, click: save},
-            {text: {/literal}'{ts escape="js"}No{/ts}'{literal}, click: function() {$(this).dialog('close');}}
+            {text: {/literal}'{ts escape="js"}Yes{/ts}'{literal}, click: save, icons: {primary: 'ui-icon-check'}},
+            {text: {/literal}'{ts escape="js"}No{/ts}'{literal}, click: function() {$(this).dialog('close');}, icons: {primary: 'ui-icon-close'}}
           ]);
         }
       });