mirror of
https://github.com/penpot/penpot.git
synced 2025-05-25 11:36:12 +02:00
♻️ Refactor dashboard (add teams)
This commit is contained in:
parent
47d347f357
commit
b3252ec2b2
52 changed files with 1842 additions and 1421 deletions
|
@ -78,7 +78,6 @@ VALUES ('00000000-0000-0000-0000-000000000000'::uuid,
|
|||
true);
|
||||
|
||||
|
||||
|
||||
CREATE TABLE team_profile_rel (
|
||||
team_id uuid NOT NULL REFERENCES team(id) ON DELETE CASCADE,
|
||||
profile_id uuid NOT NULL REFERENCES profile(id) ON DELETE RESTRICT,
|
||||
|
|
|
@ -28,9 +28,6 @@ CREATE TABLE project_profile_rel (
|
|||
PRIMARY KEY (profile_id, project_id)
|
||||
);
|
||||
|
||||
COMMENT ON TABLE project_profile_rel
|
||||
IS 'Relation between projects and profiles (NM)';
|
||||
|
||||
CREATE INDEX project_profile_rel__profile_id__idx
|
||||
ON project_profile_rel(profile_id);
|
||||
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
CREATE TABLE team_project_profile_rel (
|
||||
team_id uuid NOT NULL REFERENCES team(id) ON DELETE CASCADE,
|
||||
profile_id uuid NOT NULL REFERENCES profile(id) ON DELETE CASCADE,
|
||||
project_id uuid NOT NULL REFERENCES project(id) ON DELETE CASCADE,
|
||||
|
||||
created_at timestamptz NOT NULL DEFAULT clock_timestamp(),
|
||||
modified_at timestamptz NOT NULL DEFAULT clock_timestamp(),
|
||||
|
||||
is_pinned boolean NOT NULL DEFAULT false,
|
||||
|
||||
PRIMARY KEY (team_id, profile_id, project_id)
|
||||
);
|
|
@ -0,0 +1,4 @@
|
|||
--- Drop duplicate indexes
|
||||
|
||||
DROP INDEX IF EXISTS project_profile_rel__project_id__idx;
|
||||
DROP INDEX IF EXISTS project_profile_rel__profile_id__idx;
|
|
@ -0,0 +1 @@
|
|||
CREATE INDEX IF NOT EXISTS file__project_id__idx ON file (project_id);
|
Loading…
Add table
Add a link
Reference in a new issue