Skip to content

Commit

Permalink
Merge pull request #249 from andig/fix-legend-resolution
Browse files Browse the repository at this point in the history
Fix legend being rounded to zero decimals
  • Loading branch information
justinotherguy committed Feb 22, 2015
2 parents 27b6a3a + 5ecfbf9 commit 2e78ac1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion htdocs/frontend/javascripts/wui.js
Expand Up @@ -520,7 +520,7 @@ vz.wui.updateLegend = function() {
var d = $.plot.dateGenerator(pos.x, vz.options.plot.xaxis);
var delta = vz.options.plot.xaxis.max - vz.options.plot.xaxis.min;
var format = (delta > 1*24*3600*1000) ? '%d.%m.%y - %H:%M' : '%H:%M:%S';
vz.wui.legend.eq(i).text(series.title + ": " + $.plot.formatDate(d,format) + " - " + y.toFixed(0) + " " + series.unit);
vz.wui.legend.eq(i).text(series.title + ": " + $.plot.formatDate(d,format) + " - " + vz.wui.formatNumber(y, series.unit));
}
}

Expand Down

0 comments on commit 2e78ac1

Please sign in to comment.