Using et2_dialog for popup

This commit is contained in:
A Sigalas 2017-08-23 13:15:55 +00:00
parent b137c62815
commit e966ae332a

View File

@ -366,8 +366,13 @@
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(){
if ( confirm(egw.lang('Are you sure you want to delete all notifications?')) )
window.app.notifications.delete_all()
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()});
});