Commit 41154d6d by Torkel Ödegaard

fix(elasticsearch): fixed series naming & aliasing when using field for…

fix(elasticsearch): fixed series naming & aliasing when using field for extended_stats and percentiles
parent 9904d019
......@@ -51,7 +51,7 @@ function (_, queryDef) {
var percentiles = firstBucket[metric.id].values;
for (var percentileName in percentiles) {
newSeries = {datapoints: [], metric: 'p' + percentileName, props: props};
newSeries = {datapoints: [], metric: 'p' + percentileName, props: props, field: metric.field};
for (i = 0; i < esAgg.buckets.length; i++) {
bucket = esAgg.buckets[i];
......@@ -69,7 +69,7 @@ function (_, queryDef) {
continue;
}
newSeries = {datapoints: [], metric: statName, props: props};
newSeries = {datapoints: [], metric: statName, props: props, field: metric.field};
for (i = 0; i < esAgg.buckets.length; i++) {
bucket = esAgg.buckets[i];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment