diff --git a/src/report/report-system/html-barchart.scm b/src/report/report-system/html-barchart.scm
index a90e7ac57e..b43afbbb2c 100644
--- a/src/report/report-system/html-barchart.scm
+++ b/src/report/report-system/html-barchart.scm
@@ -456,8 +456,12 @@
autoscale: true,
},
},
+ highlighter: {
+ tooltipContentEditor: formatTooltip,
+ },
cursor:{
show: true,
+ showTooltip: false,
zoom: true
}
};\n")
@@ -495,12 +499,9 @@
(push "var plot = $.jqplot('")(push chart-id)(push"', data, options);
function formatTooltip(str, seriesIndex, pointIndex) {
- if (options.axes.xaxis.ticks[pointIndex] !== undefined)
- x = options.axes.xaxis.ticks[pointIndex];
- else
- x = pointIndex;
+ x = data[seriesIndex][pointIndex][0];
y = data[seriesIndex][pointIndex][1].toFixed(2);
- return options.series[seriesIndex].label + ' ' + x + '
' + y + '';
+ return options.series[seriesIndex].label + '
' + x + '
' + y + '';
}\n")
(push "});\n")