UI: fixed that users can't watch tournament's games

This commit is contained in:
Oleg Agafonov 2019-01-15 21:07:43 +04:00
parent 1d43b38a5f
commit 1202c1fb17
3 changed files with 133 additions and 88 deletions

View file

@ -18,6 +18,8 @@ public class TablesUtil {
searchId = ((TablesTableModel) table.getModel()).findTableAndGameInfoByRow(row);
} else if (table.getModel() instanceof MatchesTableModel) {
searchId = ((MatchesTableModel) table.getModel()).findTableAndGameInfoByRow(row);
} else if (table.getModel() instanceof TournamentMatchesTableModel) {
searchId = ((TournamentMatchesTableModel) table.getModel()).findTableAndGameInfoByRow(row);
} else {
logger.error("Not supported tables model " + table.getModel().getClass().toString());
}
@ -31,6 +33,8 @@ public class TablesUtil {
row = ((TablesTableModel) tableModel).findRowByTableAndGameInfo(searchId);
} else if (tableModel instanceof MatchesTableModel) {
row = ((MatchesTableModel) tableModel).findRowByTableAndGameInfo(searchId);
} else if (tableModel instanceof TournamentMatchesTableModel) {
row = ((TournamentMatchesTableModel) tableModel).findRowByTableAndGameInfo(searchId);
} else {
logger.error("Not supported tables model " + tableModel.getClass().toString());
}