Added migration for tables for skins
This commit is contained in:
25
migrations/20260831172036_create_table_skins.sql
Normal file
25
migrations/20260831172036_create_table_skins.sql
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
CREATE TABLE IF NOT EXISTS weapons (
|
||||||
|
id uuid DEFAULT gen_random_uuid() PRIMARY KEY,
|
||||||
|
name varchar NOT NULL,
|
||||||
|
display varchar NOT NULL,
|
||||||
|
def_index integer NOT NULL,
|
||||||
|
category varchar NOT NULL,
|
||||||
|
team integer NOT NULL -- 0 = CT, 1 = T, 2 = BOTH
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE IF NOT EXISTS rarity (
|
||||||
|
id uuid DEFAULT gen_random_uuid() PRIMARY KEY,
|
||||||
|
display varchar NOT NULL,
|
||||||
|
color varchar NOT NULL
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE IF NOT EXISTS skins (
|
||||||
|
id uuid DEFAULT gen_random_uuid() PRIMARY KEY,
|
||||||
|
weapon uuid REFERENCES weapons(id),
|
||||||
|
rarity uuid REFERENCES rarity(id),
|
||||||
|
paint_index integer NOT NULL,
|
||||||
|
display varchar NOT NULL,
|
||||||
|
min_float float NOT NULL,
|
||||||
|
max_float float NOT NULL,
|
||||||
|
legacy boolean NOT NULL
|
||||||
|
);
|
||||||
Reference in New Issue
Block a user