Migration done for the backend

This commit is contained in:
2020-04-25 18:17:34 +02:00
parent 52aae6773f
commit 69ede50a59
6 changed files with 65 additions and 37 deletions
@@ -5,9 +5,9 @@ drop table if exists Notes;
CREATE TABLE `Notes`
(
`uuid` binary(16) PRIMARY KEY,
`title` varchar(50) NOT NULL,
`user_id` int NOT NULL,
`uuid` binary(16) PRIMARY KEY,
`title` varchar(50) NOT NULL,
`user_id` int NOT NULL,
`updated_at` datetime
);
@@ -27,9 +27,10 @@ ALTER TABLE `Tags`
CREATE TABLE `Chapters`
(
`id` int PRIMARY KEY AUTO_INCREMENT,
`number` int NOT NULL,
`content` text NOT NULL,
`note_uuid` binary(16) NOT NULL
`number` int NOT NULL,
`title` varchar(50) NOT NULL,
`content` text NOT NULL,
`note_uuid` binary(16) NOT NULL
);
ALTER TABLE `Chapters`