mirror of https://github.com/M66B/FairEmail.git
Consider messages in archive as seen
This commit is contained in:
parent
0035b0e9fe
commit
bcae943c1b
|
@ -40,6 +40,7 @@ public interface DaoMessage {
|
|||
", folder.name as folderName, folder.type as folderType" +
|
||||
", COUNT(message.id) as count" +
|
||||
", SUM(CASE WHEN message.ui_seen" +
|
||||
" OR folder.type = '" + EntityFolder.ARCHIVE + "'" +
|
||||
" OR folder.type = '" + EntityFolder.OUTBOX + "'" +
|
||||
" OR folder.type = '" + EntityFolder.DRAFTS + "' THEN 0 ELSE 1 END) as unseen" +
|
||||
", (SELECT COUNT(a.id) FROM attachment a WHERE a.message = message.id) AS attachments" +
|
||||
|
@ -63,6 +64,7 @@ public interface DaoMessage {
|
|||
", folder.name as folderName, folder.type as folderType" +
|
||||
", COUNT(message.id) as count" +
|
||||
", SUM(CASE WHEN message.ui_seen" +
|
||||
" OR (folder.id <> :folder AND folder.type = '" + EntityFolder.ARCHIVE + "')" +
|
||||
" OR (folder.id <> :folder AND folder.type = '" + EntityFolder.OUTBOX + "')" +
|
||||
" OR (folder.id <> :folder AND folder.type = '" + EntityFolder.DRAFTS + "') THEN 0 ELSE 1 END) as unseen" +
|
||||
", (SELECT COUNT(a.id) FROM attachment a WHERE a.message = message.id) AS attachments" +
|
||||
|
|
Loading…
Reference in New Issue