mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2026-06-05 12:22:30 +00:00
core: api to differentiate contacts and conversations (#4111)
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
{-# LANGUAGE QuasiQuotes #-}
|
||||
|
||||
module Simplex.Chat.Migrations.M20240501_chat_deleted where
|
||||
|
||||
import Database.SQLite.Simple (Query)
|
||||
import Database.SQLite.Simple.QQ (sql)
|
||||
|
||||
m20240501_chat_deleted :: Query
|
||||
m20240501_chat_deleted =
|
||||
[sql|
|
||||
ALTER TABLE contacts ADD COLUMN chat_deleted INTEGER NOT NULL DEFAULT 0;
|
||||
|]
|
||||
|
||||
down_m20240501_chat_deleted :: Query
|
||||
down_m20240501_chat_deleted =
|
||||
[sql|
|
||||
ALTER TABLE contacts DROP COLUMN chat_deleted;
|
||||
|]
|
||||
@@ -76,6 +76,7 @@ CREATE TABLE contacts(
|
||||
contact_status TEXT NOT NULL DEFAULT 'active',
|
||||
custom_data BLOB,
|
||||
ui_themes TEXT,
|
||||
chat_deleted INTEGER NOT NULL DEFAULT 0,
|
||||
FOREIGN KEY(user_id, local_display_name)
|
||||
REFERENCES display_names(user_id, local_display_name)
|
||||
ON DELETE CASCADE
|
||||
|
||||
Reference in New Issue
Block a user