Get recipients

This commit is contained in:
M66B 2020-05-05 22:30:57 +02:00
parent e191470573
commit 691c1c7813
2 changed files with 7 additions and 0 deletions

View File

@ -49,6 +49,7 @@ public interface DaoMessage {
", folder.name AS folderName, folder.color AS folderColor, folder.display AS folderDisplay, folder.type AS folderType, folder.read_only AS folderReadOnly" +
", IFNULL(identity.display, identity.name) AS identityName, identity.email AS identityEmail, identity.synchronize AS identitySynchronize" +
", '[' || group_concat(message.`from`, ',') || ']' AS senders" +
", '[' || group_concat(message.`to`, ',') || ']' AS recipients" +
", COUNT(message.id) AS count" +
", SUM(1 - message.ui_seen) AS unseen" +
", SUM(1 - message.ui_flagged) AS unflagged" +
@ -116,6 +117,7 @@ public interface DaoMessage {
", folder.name AS folderName, folder.color AS folderColor, folder.display AS folderDisplay, folder.type AS folderType, folder.read_only AS folderReadOnly" +
", IFNULL(identity.display, identity.name) AS identityName, identity.email AS identityEmail, identity.synchronize AS identitySynchronize" +
", '[' || group_concat(message.`from`, ',') || ']' AS senders" +
", '[' || group_concat(message.`to`, ',') || ']' AS recipients" +
", COUNT(message.id) AS count" +
", SUM(1 - message.ui_seen) AS unseen" +
", SUM(1 - message.ui_flagged) AS unflagged" +
@ -178,6 +180,7 @@ public interface DaoMessage {
", folder.name AS folderName, folder.color AS folderColor, folder.display AS folderDisplay, folder.type AS folderType, folder.read_only AS folderReadOnly" +
", IFNULL(identity.display, identity.name) AS identityName, identity.email AS identityEmail, identity.synchronize AS identitySynchronize" +
", message.`from` AS senders" +
", message.`to` AS recipients" +
", 1 AS count" +
", CASE WHEN message.ui_seen THEN 0 ELSE 1 END AS unseen" +
", CASE WHEN message.ui_flagged THEN 0 ELSE 1 END AS unflagged" +
@ -363,6 +366,7 @@ public interface DaoMessage {
", folder.name AS folderName, folder.color AS folderColor, folder.display AS folderDisplay, folder.type AS folderType, folder.read_only AS folderReadOnly" +
", IFNULL(identity.display, identity.name) AS identityName, identity.email AS identityEmail, identity.synchronize AS identitySynchronize" +
", message.`from` AS senders" +
", message.`to` AS recipients" +
", 1 AS count" +
", CASE WHEN message.ui_seen THEN 0 ELSE 1 END AS unseen" +
", CASE WHEN message.ui_flagged THEN 0 ELSE 1 END AS unflagged" +
@ -393,6 +397,7 @@ public interface DaoMessage {
", folder.name AS folderName, folder.color AS folderColor, folder.display AS folderDisplay, folder.type AS folderType, folder.read_only AS folderReadOnly" +
", IFNULL(identity.display, identity.name) AS identityName, identity.email AS identityEmail, identity.synchronize AS identitySynchronize" +
", message.`from` AS senders" +
", message.`to` AS recipients" +
", 1 AS count" +
", 1 AS unseen" +
", 0 AS unflagged" +

View File

@ -47,6 +47,7 @@ public class TupleMessageEx extends EntityMessage {
public String identityEmail;
public Boolean identitySynchronize;
public Address[] senders;
public Address[] recipients;
public int count;
public int unseen;
public int unflagged;
@ -104,6 +105,7 @@ public class TupleMessageEx extends EntityMessage {
Objects.equals(this.identityEmail, other.identityEmail) &&
Objects.equals(this.identitySynchronize, other.identitySynchronize) &&
MessageHelper.equal(this.senders, other.senders) &&
MessageHelper.equal(this.recipients, other.recipients) &&
this.count == other.count &&
this.unseen == other.unseen &&
this.unflagged == other.unflagged &&