FIX: ensures we don't apply charts options to other modes (#13570)
This reverts commit 1f74ea0f08
.
This commit is contained in:
parent
4b27de8c4b
commit
33464cb07e
|
@ -300,6 +300,7 @@ export default Component.extend({
|
|||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (report.error === "not_found") {
|
||||
this.set("showFilteringUI", false);
|
||||
}
|
||||
|
@ -382,17 +383,13 @@ export default Component.extend({
|
|||
return EmberObject.create(
|
||||
Object.assign(tableOptions, this.get("reportOptions.table") || {})
|
||||
);
|
||||
} else {
|
||||
} else if (mode === "chart") {
|
||||
const chartOptions = JSON.parse(JSON.stringify(CHART_OPTIONS));
|
||||
|
||||
let chartGrouping = this.get("reportOptions.chartGrouping");
|
||||
if (!chartGrouping && report.chartData) {
|
||||
chartGrouping = Report.groupingForDatapoints(report.chartData.length);
|
||||
}
|
||||
|
||||
return EmberObject.create(
|
||||
Object.assign(chartOptions, this.get("reportOptions.chart") || {}, {
|
||||
chartGrouping,
|
||||
chartGrouping:
|
||||
this.get("reportOptions.chartGrouping") ||
|
||||
Report.groupingForDatapoints(report.chartData.length),
|
||||
})
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue