CRM-15485
authorjitendrapurohit <jitendra.purohit@webaccessglobal.com>
Mon, 20 Oct 2014 13:10:54 +0000 (18:40 +0530)
committerjitendrapurohit <jitendra.purohit@webaccessglobal.com>
Mon, 20 Oct 2014 13:10:54 +0000 (18:40 +0530)
templates/CRM/Report/Form/Actions.tpl

index 0cba19d649577c28e2b296a126710f52ebe596c2..7a8a89a9b58c470af38c78bd363136dfb1492cbd 100644 (file)
                                         CRM.confirm({
                                           message: ts({/literal}'{ts escape='js' 1='<em>%1</em>'}Add all contacts to %1 group?{/ts}'{literal}, {1: $('option:selected', '#groups').text()})
                                         })
-                                          .on('crmConfirm:yes', function() {
-                                            $('#groups').siblings(':submit').click();
+                                          .on({
+                                            'crmConfirm:yes': function() {
+                                              $('#groups').siblings(':submit').click();
+                                            },
+                                            'crmConfirm:no dialogclose': function() {
+                                              $('#groups').select2('val', '');
+                                            }
                                           });
-                                        $('#groups').select2('val', '');
                                       });
                                     })(CRM.$);
                                     {/literal}