Added World Name to GameMode slices (#491)

This commit is contained in:
Rsl1122 2018-02-01 18:17:53 +02:00
parent a6bd3eadcc
commit 98d55b2ff2
2 changed files with 16 additions and 5 deletions

View File

@ -1,14 +1,25 @@
function worldPie(id, worldSeries, gmSeries) {
Highcharts.chart(id, {
var defaultTitle = '';
var defaultSubtitle = 'Click the slices to view used GameMode';
var chart = Highcharts.chart(id, {
chart: {
plotBackgroundColor: null,
plotBorderWidth: null,
plotShadow: false,
type: 'pie'
type: 'pie',
events: {
drilldown: function (e) {
chart.setTitle({text: '' + e.point.name}, {text: ''});
},
title: {text: ''},
drillup: function (e) {
chart.setTitle({text: defaultTitle}, {text: defaultSubtitle});
}
}
},
title: {text: defaultTitle},
subtitle: {
text: 'Click the slices to view used GameMode'
text: defaultSubtitle
},
plotOptions: {
pie: {

View File

@ -53,7 +53,7 @@ public class LiteBansData extends PluginData implements BanData {
List<LiteBansDBObj> warns = db.getWarnings(uuid);
List<LiteBansDBObj> kicks = db.getKicks(uuid);
if (bans.isEmpty() && mutes.isEmpty() && warns.isEmpty() && kicks.isEmpty()) {
table.addRow("Not Banned/Muted/Warned/Kicked");
table.addRow("None");
} else {
for (LiteBansDBObj ban : bans) {
long expiry = ban.getExpiry();