sleact
Tables (8)
ChannelMembers
- ChannelId — int — Foreign key → channels.id — NOT NULL
- UserId — int — Foreign key → users.id — NOT NULL
- createdAt — datetime — NOT NULL
- updatedAt — datetime — NOT NULL
channelChats
- id — int — Primary key — NOT NULL
- content — text — NOT NULL
- createdAt — datetime — NOT NULL
- updatedAt — datetime — NOT NULL
- ChannelId — int — Foreign key → channels.id
- UserId — int — Foreign key → users.id
channels
- id — int — Primary key — NOT NULL
- name — varchar(30) — NOT NULL
- private — tinyint(1)
- createdAt — datetime — NOT NULL
- updatedAt — datetime — NOT NULL
- WorkspaceId — int — Foreign key → workspaces.id
dms
- id — int — Primary key — NOT NULL
- WorkspaceId — int — Foreign key → workspaces.id
- content — text — NOT NULL
- createdAt — datetime — NOT NULL
- updatedAt — datetime — NOT NULL
- ReceiverId — int — Foreign key → users.id
- SenderId — int — Foreign key → users.id
mentions
- id — int — Primary key — NOT NULL
- category — enum('chat','dm','system') — NOT NULL
- chatId — int
- createdAt — datetime — NOT NULL
- updatedAt — datetime — NOT NULL
- WorkspaceId — int — Foreign key → workspaces.id
- SenderId — int — Foreign key → users.id
- ReceiverId — int — Foreign key → users.id
users
- id — int — Primary key — NOT NULL
- email — varchar(30) — NOT NULL
- nickname — varchar(30) — NOT NULL
- password — varchar(100) — NOT NULL
- createdAt — datetime — NOT NULL
- updatedAt — datetime — NOT NULL
- deletedAt — datetime
workspacemembers
- WorkspaceId — int — Foreign key → workspaces.id — NOT NULL
- UserId — int — Foreign key → users.id — NOT NULL
- loggedInAt — datetime
- createdAt — datetime — NOT NULL
- updatedAt — datetime — NOT NULL
workspaces
- id — int — Primary key — NOT NULL
- name — varchar(30) — NOT NULL
- url — varchar(30) — NOT NULL
- createdAt — datetime — NOT NULL
- updatedAt — datetime — NOT NULL
- deletedAt — datetime
- OwnerId — int — Foreign key → users.id