Support $HasAttachment/$HasNoAttachment keywords (#6201)

We use these only to display the attachment icon on the messages list.
pull/6772/head
Aleksander Machniak 6 years ago
parent f8ca8d1b63
commit 4ef87fe856

@ -6,6 +6,7 @@ CHANGELOG Roundcube Webmail
- Added cookie mismatch detection, display an error message informing the user to clear cookies
- Renamed 'log_session' option to 'session_debug'
- Don't log full session identifiers in userlogins log (#6625)
- Support $HasAttachment/$HasNoAttachment keywords (#6201)
- installto.sh: Add possibility to run the update even on the up-to-date installation (#6533)
- Redis: Support connection to unix socket
- Elastic: Add Prev/Next buttons on message page toolbar (#6648)

@ -2285,12 +2285,12 @@ function rcube_webmail()
label = this.get_label('withattachment');
if (flags.attachmentClass)
html = '<span class="'+flags.attachmentClass+'" title="'+label+'"></span>';
else if (/application\/|multipart\/(m|signed)/.test(flags.ctype))
html = '<span class="attachment" title="'+label+'"></span>';
else if (/multipart\/report/.test(flags.ctype))
else if (flags.ctype == 'multipart/report')
html = '<span class="report"></span>';
else if (flags.ctype == 'multipart/encrypted' || flags.ctype == 'application/pkcs7-mime')
html = '<span class="encrypted"></span>';
else if (flags.hasattachment || (!flags.hasnoattachment && /application\/|multipart\/(m|signed)/.test(flags.ctype)))
html = '<span class="attachment" title="'+label+'"></span>';
else
html = '&nbsp;';
}

@ -97,6 +97,8 @@ class rcube_imap_cache
8192 => 'LABEL3',
16384 => 'LABEL4',
32768 => 'LABEL5',
65536 => 'HASATTACHMENT',
131072 => 'HASNOATTACHMENT',
);

Loading…
Cancel
Save