mirror of
https://github.com/Lynnesbian/FediBooks/
synced 2024-11-25 16:48:58 +00:00
add table for accounts bot is learning from
This commit is contained in:
parent
556dea9fae
commit
025b56e1b6
1 changed files with 7 additions and 1 deletions
|
@ -34,7 +34,7 @@ CREATE TABLE IF NOT EXISTS `bots` (
|
||||||
FOREIGN KEY (`user_id`) REFERENCES users(id) ON DELETE CASCADE,
|
FOREIGN KEY (`user_id`) REFERENCES users(id) ON DELETE CASCADE,
|
||||||
FOREIGN KEY (`credentials_id`) REFERENCES credentials(id) ON DELETE CASCADE
|
FOREIGN KEY (`credentials_id`) REFERENCES credentials(id) ON DELETE CASCADE
|
||||||
) ENGINE=INNODB;
|
) ENGINE=INNODB;
|
||||||
CREATE TABLE IF NOT EXISTS `fedi_account` (
|
CREATE TABLE IF NOT EXISTS `fedi_accounts` (
|
||||||
`handle` VARCHAR(128) PRIMARY KEY,
|
`handle` VARCHAR(128) PRIMARY KEY,
|
||||||
`outbox` VARCHAR(256),
|
`outbox` VARCHAR(256),
|
||||||
`credentials_id` INT NOT NULL,
|
`credentials_id` INT NOT NULL,
|
||||||
|
@ -42,6 +42,12 @@ CREATE TABLE IF NOT EXISTS `fedi_account` (
|
||||||
`icon_update_time` DATETIME DEFAULT 0,
|
`icon_update_time` DATETIME DEFAULT 0,
|
||||||
FOREIGN KEY (`credentials_id`) REFERENCES credentials(id) ON DELETE CASCADE
|
FOREIGN KEY (`credentials_id`) REFERENCES credentials(id) ON DELETE CASCADE
|
||||||
) ENGINE=INNODB;
|
) ENGINE=INNODB;
|
||||||
|
CREATE TABLE IF NOT EXISTS `bot_learned_accounts` (
|
||||||
|
`bot_id` BINARY(64) NOT NULL,
|
||||||
|
`fedi_id` VARCHAR(128) NOT NULL,
|
||||||
|
FOREIGN KEY (`bot_id`) REFERENCES bots(id) ON DELETE CASCADE,
|
||||||
|
FOREIGN KEY (`fedi_id`) REFERENCES fedi_accounts(handle) ON DELETE CASCADE
|
||||||
|
) ENGINE=INNODB;
|
||||||
CREATE TABLE IF NOT EXISTS `posts` (
|
CREATE TABLE IF NOT EXISTS `posts` (
|
||||||
`id` BIGINT AUTO_INCREMENT PRIMARY KEY,
|
`id` BIGINT AUTO_INCREMENT PRIMARY KEY,
|
||||||
`fedi_id` VARCHAR(128),
|
`fedi_id` VARCHAR(128),
|
||||||
|
|
Loading…
Reference in a new issue