mirror of
https://github.com/apache/superset.git
synced 2026-04-18 23:55:00 +00:00
fix: lost renameOperator in mixed timeseries chart (#19802)
This commit is contained in:
@@ -22,7 +22,11 @@ import {
|
||||
QueryObject,
|
||||
normalizeOrderBy,
|
||||
} from '@superset-ui/core';
|
||||
import { flattenOperator, pivotOperator } from '@superset-ui/chart-controls';
|
||||
import {
|
||||
pivotOperator,
|
||||
renameOperator,
|
||||
flattenOperator,
|
||||
} from '@superset-ui/chart-controls';
|
||||
|
||||
export default function buildQuery(formData: QueryFormData) {
|
||||
const {
|
||||
@@ -66,7 +70,11 @@ export default function buildQuery(formData: QueryFormData) {
|
||||
is_timeseries: true,
|
||||
post_processing: [
|
||||
pivotOperator(formData1, { ...baseQueryObject, is_timeseries: true }),
|
||||
flattenOperator(formData1, { ...baseQueryObject, is_timeseries: true }),
|
||||
renameOperator(formData1, {
|
||||
...baseQueryObject,
|
||||
...{ is_timeseries: true },
|
||||
}),
|
||||
flattenOperator(formData1, baseQueryObject),
|
||||
],
|
||||
} as QueryObject;
|
||||
return [normalizeOrderBy(queryObjectA)];
|
||||
@@ -78,7 +86,11 @@ export default function buildQuery(formData: QueryFormData) {
|
||||
is_timeseries: true,
|
||||
post_processing: [
|
||||
pivotOperator(formData2, { ...baseQueryObject, is_timeseries: true }),
|
||||
flattenOperator(formData2, { ...baseQueryObject, is_timeseries: true }),
|
||||
renameOperator(formData2, {
|
||||
...baseQueryObject,
|
||||
...{ is_timeseries: true },
|
||||
}),
|
||||
flattenOperator(formData2, baseQueryObject),
|
||||
],
|
||||
} as QueryObject;
|
||||
return [normalizeOrderBy(queryObjectB)];
|
||||
|
||||
Reference in New Issue
Block a user