增加私聊置顶和按设备统计未读
This commit is contained in:
1 parent
7e165ba9b4
commit
ec2679b991
19 files changed
+312
-52
No files matched your search
@@ -0,0 +1,13 @@
|
||||
ALTER TABLE contact_preferences ADD COLUMN pinned boolean NOT NULL DEFAULT false;
|
||||
ALTER TABLE device_envelopes ADD COLUMN counts_as_unread boolean NOT NULL DEFAULT false;
|
||||
|
||||
CREATE INDEX device_envelopes_unread ON device_envelopes(recipient_device, sender_device, sequence)
|
||||
WHERE counts_as_unread;
|
||||
|
||||
CREATE TABLE device_contact_seen (
|
||||
recipient_device uuid NOT NULL REFERENCES devices(id) ON DELETE CASCADE,
|
||||
sender_device uuid NOT NULL REFERENCES devices(id) ON DELETE CASCADE,
|
||||
sequence bigint NOT NULL CHECK (sequence > 0),
|
||||
PRIMARY KEY (recipient_device, sender_device),
|
||||
CHECK (recipient_device <> sender_device)
|
||||
);
|
||||
Reference in new issue
Block a user