Admin page raid group tab working

This commit is contained in:
2025-03-05 20:12:32 -05:00
parent f528cbaa2b
commit aff81e27eb
23 changed files with 624 additions and 7 deletions

View File

@@ -2,6 +2,8 @@ CREATE TABLE IF NOT EXISTS raid_builder.game(
game_id uuid PRIMARY KEY,
game_name text UNIQUE NOT NULL,
game_icon text,
--Auditing
modified_by uuid,
modified_date timestamptz,
created_by uuid NOT NULL,

View File

@@ -8,9 +8,9 @@ CREATE TABLE IF NOT EXISTS raid_builder.game_permission(
game_permission_type raid_builder.game_permission_type NOT NULL,
--Auditing
modified_by uuid REFERENCES raid_builder.account(account_id) NOT NULL,
modified_date timestamptz NOT NULL,
created_by uuid REFERENCES raid_builder.account(account_id) NOT NULL,
modified_by uuid,
modified_date timestamptz,
created_by uuid NOT NULL,
created_date timestamptz NOT NULL
);

View File

@@ -0,0 +1,14 @@
CREATE TABLE IF NOT EXISTS raid_builder.raid_group(
raid_group_id uuid PRIMARY KEY,
game_id uuid REFERENCES raid_builder.game(game_id) NOT NULL,
raid_group_name text NOT NULL,
raid_group_icon text,
--Auditing
modified_by uuid,
modified_date timestamptz,
created_by uuid NOT NULL,
created_date timestamptz NOT NULL
);
GRANT ALL ON TABLE raid_builder.raid_group TO raid_builder;

View File

@@ -0,0 +1,17 @@
CREATE TYPE raid_builder.raid_group_permission_type AS ENUM ( 'ADMIN', 'LEADER', 'RAIDER' );
CREATE TABLE IF NOT EXISTS raid_builder.raid_group_permission(
raid_group_permission_id uuid PRIMARY KEY,
account_id uuid REFERENCES raid_builder.account(account_id) NOT NULL,
raid_group_id uuid REFERENCES raid_builder.raid_group(raid_group_id) NOT NULL,
permission raid_builder.raid_group_permission_type NOT NULL,
--Auditing
modified_by uuid NOT NULL,
modified_date timestamptz,
created_by uuid NOT NULL,
created_date timestamptz NOT NULL
);
GRANT ALL ON TABLE raid_builder.raid_group_permission TO raid_builder;