12 lines
590 B
SQL
12 lines
590 B
SQL
-- Проектные каналы Slack: канал привязан к проекту (объекту стройки) JobTread, поэтому проект в общении не уточняется.
|
|
create table if not exists project_channel (
|
|
channel_id text primary key,
|
|
jt_job_id text not null,
|
|
channel_name text,
|
|
is_enabled boolean not null default true,
|
|
note text,
|
|
created_at timestamptz not null default now()
|
|
);
|
|
create index if not exists project_channel_job_idx on project_channel (jt_job_id);
|
|
alter table project_channel enable row level security;
|