I create chart and I have problem with connect series data with tooltip. I created array, like below which i fill data.
for (var i = 0; i < ChartData.SeriesList.length; i++) {
Series.push({
data: ChartData.SeriesList[i].Values,
name: ChartData.SeriesList[i].SeriesName,
time: ChartData.SeriesList[i].ExactDate
});
}
then I create kendo chart
$("#chart").kendoChart({
title: {
text: "Sprzedaż"
},
legend: {
position: "bottom"
},
chartArea: {
background: ""
},
seriesDefaults: {
type: "line",
style: "smooth"
},
dataSource: {
data: Series
},
series: Series,
valueAxis: {
labels: {
format: "{0}"
},
line: {
visible: false
},
axisCrossingValue: -10
},
categoryAxis: {
categories: tab.length > 0 ? tab : ChartData.AxisValue,
majorGridLines: {
visible: false
},
labels: {
rotation: "auto"
}
},
tooltip: {
visible: true,
format: "{0}",
template: "#= series.name #: #= dataItem #"
}
});
}
And now I would like to print Series.time value at tooltip, but when I wrote this:
tooltip: {
visible: true,
format: "{0}",
template: "#= series.name #: #= data.series.time #"
}
I have all data which are at series.time not one which should be. Maybe someone know how to connect this array with tooltip so that print one correct value.