* Mail: Fix deleting or moving multiple mail to another folder did not update the list

This commit is contained in:
nathangray 2020-08-24 12:35:06 -06:00
parent f87a5e0b5d
commit 8628b50ffb
2 changed files with 10 additions and 7 deletions

View File

@ -5538,7 +5538,11 @@ $filter['before']= date("d-M-Y", $cutoffdate2);
{
$msg = lang('moved %1 message(s) from %2 to %3',($messageList=='all'||$_messageList['all']?($filtered?lang('all filtered'):lang('all')):count($messageList)),lang($folder),lang($targetFolder));
if ($_return) return $msg;
$response->call('egw.refresh',$msg,'mail',$messageListForRefresh,'delete');
foreach($messageListForRefresh as $mail_id)
{
$response->call('egw.refresh','','mail',$mail_id, 'delete');
}
$response->message($msg,'success');
}
}
if ($changeFolderActions == true)

View File

@ -2189,11 +2189,7 @@ app.classes.mail = AppJS.extend(
mail_deleteMessagesShowResult: function(_msg)
{
// Update list
var ids = [];
for (var i = 0; i < _msg['msg'].length; i++)
{
ids.push(_msg['msg'][i].replace(/mail::/,''));
}
//this.egw.message(_msg['egw_message']);
if (_msg['all'])
{
@ -2201,7 +2197,10 @@ app.classes.mail = AppJS.extend(
}
else
{
this.egw.refresh(_msg['egw_message'],'mail',ids,'delete');
for (var i = 0; i < _msg['msg'].length; i++)
{
this.egw.refresh(_msg['egw_message'], 'mail', _msg['msg'][i].replace(/mail::/,''), 'delete');
}
// Nextmatch automatically selects the next row and calls preview.
// Unselect it and thanks to the timeout selectionMgr uses, preview