Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions db/dummy_data.sql
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,14 @@ INSERT INTO `user_contact` VALUES
UNLOCK TABLES;


LOCK TABLES `user_manager` WRITE;
/*!40000 ALTER TABLE `user_manager` DISABLE KEYS */;
INSERT INTO `user_manager` VALUES
(3, 2),
(2, 1);
/*!40000 ALTER TABLE `user_manager` ENABLE KEYS */;
UNLOCK TABLES;

LOCK TABLES `event` WRITE;
/*!40000 ALTER TABLE `event` DISABLE KEYS */;
INSERT INTO `event` (`id`, `team_id`, `role_id`, `schedule_id`, `user_id`, `start`, `end`) VALUES
Expand Down
13 changes: 13 additions & 0 deletions db/schema.v0.sql
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,19 @@ CREATE TABLE IF NOT EXISTS `user_contact` (
ON DELETE CASCADE
);

-- -----------------------------------------------------
-- Table `user_manager`
-- -----------------------------------------------------
CREATE TABLE IF NOT EXISTS `user_manager` (
`report_id` BIGINT(20) UNSIGNED NOT NULL,
`manager_id` BIGINT(20) UNSIGNED NOT NULL,
PRIMARY KEY (`report_id`),
CONSTRAINT `user_manager_report_id_fk` FOREIGN KEY (`report_id`) REFERENCES `user` (`id`)
ON DELETE CASCADE,
CONSTRAINT `user_manager_manager_id_fk` FOREIGN KEY (`manager_id`) REFERENCES `user` (`id`)
ON DELETE CASCADE
);

-- -----------------------------------------------------
-- Table `audit`
-- -----------------------------------------------------
Expand Down