Bar chart updated

This commit is contained in:
projectsodoo 2021-01-18 23:01:38 +05:30
parent bec7b95d0b
commit 105261a6bb
1 changed files with 3 additions and 15 deletions

View File

@ -9,18 +9,9 @@ var MAX_LEGEND_LENGTH = 25 * (1 + config.device.size_class);
GraphRenderer.include({
init: function(parent, state, params) {
this._super.apply(this, arguments);
console.log("Dataset Name", this);
this.title = 'Time line'
if (this.params && this.params.title) {
this.params.title = '111Time line'
}
console.log("Module Name", arguments);
console.log("this parent", parent);
console.log("this state", state);
console.log("this params", params);
},
_getElementOptions: function () {
_animationOptions: function () {
var animationOptions = {};
if (this.state.mode === 'bar') {
var animationOptions = {
@ -53,7 +44,7 @@ var MAX_LEGEND_LENGTH = 25 * (1 + config.device.size_class);
legend: this._getLegendOptions(datasetsCount),
tooltips: this._getTooltipOptions(),
elements: this._getElementOptions(),
animation: this._getElementOptions(),
animation: this._animationOptions(),
};
if (this._isRedirectionEnabled()) {
options.onClick = this._onGraphClicked.bind(this);
@ -76,10 +67,7 @@ var MAX_LEGEND_LENGTH = 25 * (1 + config.device.size_class);
});
// prepare options
var options = this._prepareOptions(data.datasets.length);
console.log("rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr chart data>>>>>>>>>>>>>>>>", data)
console.log("rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr chart>>>>>>>>>>>>>>>>", options)
console.log("rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr chart>>>>>>>>>>>>>>>>", JSON.stringify(options))
var options = this._prepareOptions(data.datasets.length);
// create chart
var ctx = document.getElementById(this.chartId);
this.chart = new Chart(ctx, {