From 64d5f91e8f7871fa91d5d015d51fd3b56a0b7997 Mon Sep 17 00:00:00 2001 From: Jonathan Williams Date: Thu, 14 Apr 2016 18:49:20 -0500 Subject: [PATCH] Remove TeamInvite table. --- .../src/mineplex/core/tournament/TournamentManager.java | 4 +++- .../mineplex/core/tournament/data/TournamentInviteStatus.java | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Plugins/Mineplex.Core/src/mineplex/core/tournament/TournamentManager.java b/Plugins/Mineplex.Core/src/mineplex/core/tournament/TournamentManager.java index 85eaa3ab5..3314c706f 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/tournament/TournamentManager.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/tournament/TournamentManager.java @@ -7,6 +7,7 @@ import java.util.UUID; import org.bukkit.entity.Player; import org.bukkit.plugin.java.JavaPlugin; +import org.bukkit.scoreboard.Team; import mineplex.core.MiniDbClientPlugin; import mineplex.core.account.CoreClientManager; @@ -39,7 +40,7 @@ public class TournamentManager extends MiniDbClientPlugin @Override public String getQuery(int accountId, String uuid, String name) { - return "SELECT TT.id, TT.tournamentId, accounts.id, accounts.uuid, accounts.name, TTI.status FROM tournamentTeams AS TT INNER JOIN accounts ON accounts.id = TT.accountId LEFT JOIN tournamentTeamInvites AS TTI ON TTI.teamId = TT.id WHERE TT.accountId = " + accountId + ";"; + return "SELECT TT.id, TT.tournamentId, accounts.id, accounts.uuid, accounts.name, TT.status FROM tournamentTeams AS TT INNER JOIN accounts ON accounts.id = TT.accountId WHERE TT.accountId = " + accountId + ";"; } @Override @@ -114,6 +115,7 @@ public class TournamentManager extends MiniDbClientPlugin if (success) { player.sendMessage(F.main(getName(), "You have successfully registered for " + tournament.Name + " tournament!")); + TournamentTeam team = new TournamentTeam(); } else { diff --git a/Plugins/Mineplex.Core/src/mineplex/core/tournament/data/TournamentInviteStatus.java b/Plugins/Mineplex.Core/src/mineplex/core/tournament/data/TournamentInviteStatus.java index 6ad1414c4..c21f6af0b 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/tournament/data/TournamentInviteStatus.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/tournament/data/TournamentInviteStatus.java @@ -4,5 +4,6 @@ public enum TournamentInviteStatus { INVITED, ACCEPTED, - DENIED + DENIED, + OWNER }