Overhauled all references to deck construction to include target format. Altered deck builder to only show the validations for the selected target format. Expanded the deck builder validation to show all problems with the deck instead of just one. Added target format to the list of decks. Expanded the error message in the game hall when an invalid deck is chosen for a given format. Added the target format into the deck selection dropdown in the main hall.
27 lines
521 B
SQL
27 lines
521 B
SQL
SELECT *
|
|
FROM gemp_db.deck d
|
|
ORDER BY ID DESC
|
|
|
|
|
|
ALTER TABLE gemp_db.deck
|
|
ADD COLUMN target_format VARCHAR(50) NOT NULL DEFAULT 'Anything Goes' AFTER name;
|
|
|
|
ALTER TABLE gemp_db.deck
|
|
MODIFY COLUMN name VARCHAR(100) NOT NULL;
|
|
|
|
ALTER TABLE gemp_db.deck ADD FOREIGN KEY (player_id) REFERENCES gemp_db.player(id);
|
|
|
|
|
|
|
|
-- DELETE
|
|
-- SELECT *
|
|
FROM gemp_db.deck
|
|
-- LEFT JOIN gemp_db.player p
|
|
-- ON P.id = d.player_id
|
|
WHERE player_id IN (1, 2, 7)
|
|
ORDER BY D.ID DESC
|
|
|
|
|
|
SELECT *
|
|
FROM gemp_db.player p
|
|
WHERE p.id IN (1, 2, 7) |