feat: added sync group table and models
This commit is contained in:
parent
320a46c0f3
commit
4a45bebc9f
6 changed files with 52 additions and 0 deletions
|
|
@ -24,6 +24,9 @@ create table devices (
|
|||
user_id bigint not null
|
||||
references users (id)
|
||||
on delete cascade,
|
||||
sync_group_id bigint
|
||||
references sync_group (id)
|
||||
on delete set null,
|
||||
|
||||
caption text not null,
|
||||
type text not null,
|
||||
|
|
@ -31,6 +34,10 @@ create table devices (
|
|||
unique (user_id, device_id)
|
||||
);
|
||||
|
||||
create table sync_groups (
|
||||
id integer primary key not null
|
||||
);
|
||||
|
||||
create table device_subscriptions (
|
||||
id integer primary key not null,
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue