Added more functionality for admins

This commit is contained in:
Isaac Parenteau
2019-12-30 20:22:20 -06:00
parent 75c3892e61
commit fd3c942164
8 changed files with 268 additions and 10 deletions

View File

@@ -7,6 +7,7 @@
<class>net.locusworks.discord.eighttrack.database.entities.DiscordGuild</class>
<class>net.locusworks.discord.eighttrack.database.entities.Song</class>
<class>net.locusworks.discord.eighttrack.database.entities.GuildPlaylistSong</class>
<class>net.locusworks.discord.eighttrack.database.entities.Log</class>
<properties>
<property name="javax.persistence.jdbc.url" value="jdbc:mariadb://devops.locusworks.net:3306/eighttrack"/>
<property name="javax.persistence.jdbc.user" value="root"/>

View File

@@ -0,0 +1,10 @@
CREATE TABLE eighttrack.log (
id bigint(20) NOT NULL AUTO_INCREMENT,
guild bigint(20) NOT NULL,
log longtext NOT NULL,
is_exception tinyint(1) NOT NULL,
date_added timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
PRIMARY KEY (id),
KEY log_fk (guild),
CONSTRAINT log_fk FOREIGN KEY (guild) REFERENCES eighttrack.discord_guild (id) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8;