fix problem(s) with display of attachments on forward when either forwarding inline with several attachments to the forwarded message or forwarding multiple messages as attachment

This commit is contained in:
Klaus Leithoff 2015-02-12 15:19:24 +00:00
parent 0df9400f46
commit d15d01a8b4
2 changed files with 3 additions and 2 deletions

View File

@ -1967,7 +1967,7 @@ class mail_ui
$preventRedirect=false;
if(isset($_requesteddata['id'])) $rowID = $_requesteddata['id'];
if(isset($_requesteddata['part'])) $partID = $_requesteddata['part'];
if(isset($_requesteddata['part'])) $partID = $_requesteddata['part']!='null'?$_requesteddata['part']:null;
if(isset($_requesteddata['mode'])) $preventRedirect = (($_requesteddata['mode']=='display' || $_requesteddata['mode'] == 'print')?true:false);
$hA = self::splitRowID($rowID);

View File

@ -2239,7 +2239,8 @@ app.classes.mail = AppJS.extend(
attgrid = this.et2.getArrayMgr("content").getEntry('attachments')[widget.id.replace(/\[name\]/,'')];
var mailids = this.et2.getArrayMgr("content").getEntry('processedmail_id');
var mailida = mailids.split(',');
mailid = mailida[widget.id.replace(/\[name\]/,'')];
// either several attachments of one email, or multiple emlfiles
mailid = mailida.length==1 ? mailida[0] : mailida[widget.id.replace(/\[name\]/,'')];
if (typeof attgrid.uid != 'undefined' && attgrid.uid && mailid.indexOf(attgrid.uid)==-1)
{
for (var i=0; i<mailida.length; i++)