Mail folder management dialog:

- Add delete confirmation dialog in order to warn user
This commit is contained in:
Hadi Nategh 2015-08-13 11:54:50 +00:00
parent fb6d06e322
commit 6a1f5393e4

View File

@ -4969,6 +4969,10 @@ app.classes.mail = AppJS.extend(
var tree = etemplate2.getByApplication('mail')[0].widgetContainer.getWidgetById('tree'); var tree = etemplate2.getByApplication('mail')[0].widgetContainer.getWidgetById('tree');
var menuaction= 'mail.mail_ui.ajax_folderMgmt_delete'; var menuaction= 'mail.mail_ui.ajax_folderMgmt_delete';
var callbackDialog = function(_btn)
{
if (_btn === et2_dialog.YES_BUTTON)
{
if (tree) if (tree)
{ {
var selFolders = tree.input.getAllChecked(); var selFolders = tree.input.getAllChecked();
@ -4997,6 +5001,10 @@ app.classes.mail = AppJS.extend(
} }
} }
} }
};
et2_dialog.show_dialog(callbackDialog, egw.lang('Are you sure you want to delete all selected folders?'), egw.lang('Delete folders'), {},
et2_dialog.BUTTON_YES_NO, et2_dialog.WARNING_MESSAGE, undefined, egw);
}
}); });