diff --git a/notifications/js/notificationajaxpopup.js b/notifications/js/notificationajaxpopup.js index 634b4436a2..a44bda3444 100644 --- a/notifications/js/notificationajaxpopup.js +++ b/notifications/js/notificationajaxpopup.js @@ -365,7 +365,15 @@ // toggle notifications bar jQuery('.egwpopup_toggle').click(function(){window.app.notifications.toggle();}); jQuery('#egwpopup_fw_notifications').click(function(){window.app.notifications.toggle();}); - jQuery(".egwpopup_deleteall", '#egwpopup').click(function(){window.app.notifications.delete_all()}); + jQuery(".egwpopup_deleteall", '#egwpopup').click(function(){ + et2_dialog.show_dialog( function(_button){ + if (_button == 2) window.app.notifications.delete_all(); + }, + egw.lang('Are you sure you want to delete all notifications?'), + egw.lang('Delete notifications'), + null, et2_dialog.BUTTON_YES_NO, et2_dialog.WARNING_MESSAGE, undefined, egw + ); + }); jQuery(".egwpopup_seenall", '#egwpopup').click(function(){window.app.notifications.mark_all_seen()}); }); })();