public ChartJsoptions GetOptions() { ChartJsoptions chartoptions = new ChartJsoptions(); ChartJSoptionsScalesY yAxes = new ChartJSoptionsScalesY(); yAxes.ticks.beginAtZero = true; chartoptions.scales.yAxes.Add(yAxes); chartoptions.title.display = true; return(chartoptions); }
public ChartJsoptions GetOptions() { ChartJsoptions chartoptions = new ChartJsoptions(); if (_options.Mode == "Synergy" || _options.Mode == "AntiSynergy") { ChartJsoptionsradar radaroptions = new ChartJsoptionsradar(); radaroptions.title.text = _options.Mode; radaroptions.legend.position = "bottom"; if (_options.Player == true) { radaroptions.title.text = "Player " + radaroptions.title.text; } chartoptions = radaroptions; } else { ChartJsoptionsBar baroptions = new ChartJsoptionsBar(); chartoptions = baroptions; ChartJSoptionsScalesY yAxes = new ChartJSoptionsScalesY(); yAxes.scaleLabel.labelString = "% - " + _options.Startdate.ToString("yyyy-MM-dd") + " - " + _options.Enddate.ToString("yyyy-MM-dd") + " - " + IsDefaultFilter(); if (_options.BeginAtZero == true) { yAxes.ticks.beginAtZero = true; } chartoptions.scales.yAxes.Add(yAxes); } chartoptions.title.display = true; chartoptions.title.text = _options.Mode; if (_options.Player == true) { chartoptions.title.text = "Player " + chartoptions.title.text; } return(chartoptions); }