users table endpoints. auth to fix
This commit is contained in:
19
tables.sql
Normal file
19
tables.sql
Normal file
@ -0,0 +1,19 @@
|
||||
CREATE TABLE public.users (
|
||||
id serial NOT NULL,
|
||||
username text NOT NULL,
|
||||
"password" text NOT NULL,
|
||||
groups_ids integer[] NULL,
|
||||
last_seen_at timestamp with time zone NULL,
|
||||
created_at timestamp with time zone NULL,
|
||||
CONSTRAINT userid_pk PRIMARY KEY (id),
|
||||
CONSTRAINT username_unique UNIQUE (username)
|
||||
);
|
||||
|
||||
CREATE TABLE public.groups (
|
||||
id serial NOT NULL,
|
||||
groupname text NOT NULL,
|
||||
join_code text NOT NULL,
|
||||
users_ids integer[] NULL,
|
||||
created_at timestamp with time zone NULL,
|
||||
CONSTRAINT groupname_unique UNIQUE (username)
|
||||
);
|
||||
Reference in New Issue
Block a user