Initial commmit
This commit is contained in:
commit
88383f90e5
1174 changed files with 227188 additions and 0 deletions
3
migrations/2022-11-15-2045_create-showings/down.sql
Normal file
3
migrations/2022-11-15-2045_create-showings/down.sql
Normal file
|
@ -0,0 +1,3 @@
|
|||
use movienight;
|
||||
|
||||
DROP TABLE sessions;
|
17
migrations/2022-11-15-2045_create-showings/up.sql
Normal file
17
migrations/2022-11-15-2045_create-showings/up.sql
Normal file
|
@ -0,0 +1,17 @@
|
|||
USE movienight;
|
||||
|
||||
CREATE TABLE IF NOT EXISTS showings
|
||||
(
|
||||
id INTEGER AUTO_INCREMENT PRIMARY KEY,
|
||||
schedule_id INTEGER,
|
||||
movie_id INTEGER,
|
||||
showtime DATETIME,
|
||||
public BOOL default FALSE,
|
||||
owner INTEGER NOT NULL,
|
||||
created_at DATETIME NOT NULL,
|
||||
updated_at DATETIME NOT NULL,
|
||||
deleted_at DATETIME,
|
||||
FOREIGN KEY (movie_id) REFERENCES movies (id),
|
||||
FOREIGN KEY (schedule_id) REFERENCES schedules (id),
|
||||
FOREIGN KEY (owner) REFERENCES users (id)
|
||||
);
|
Loading…
Add table
Add a link
Reference in a new issue