mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Missing values, correct timeStep
This commit is contained in:
parent
d1e8418c74
commit
2cdd097b3a
@ -271,8 +271,14 @@ module.directive('grafanaGraph', function($rootScope, timeSrv) {
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
if (data.length && data[0].stats.timeStep) {
|
||||
options.series.bars.barWidth = data[0].stats.timeStep / 1.5;
|
||||
var width;
|
||||
for (let i = 0; i < data.length; i++) {
|
||||
if (data[i].stats.timeStep && (width == null || (data[i].stats.timeStep / 1.5) < width)) {
|
||||
width = data[i].stats.timeStep / 1.5;
|
||||
}
|
||||
}
|
||||
if (width) {
|
||||
options.series.bars.barWidth = width;
|
||||
}
|
||||
addTimeAxis(options);
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user