mirror of
https://github.com/apache/superset.git
synced 2026-04-22 09:35:23 +00:00
fix(plugin-chart-echarts): support forced categorical x-axis (#26404)
This commit is contained in:
@@ -229,8 +229,10 @@ export function sortRows(
|
||||
}
|
||||
|
||||
const value =
|
||||
xAxisSortSeries === SortSeriesType.Name && typeof sortKey === 'string'
|
||||
? sortKey.toLowerCase()
|
||||
xAxisSortSeries === SortSeriesType.Name
|
||||
? typeof sortKey === 'string'
|
||||
? sortKey.toLowerCase()
|
||||
: sortKey
|
||||
: aggregate;
|
||||
|
||||
return {
|
||||
@@ -515,8 +517,12 @@ export function sanitizeHtml(text: string): string {
|
||||
|
||||
export function getAxisType(
|
||||
stack: StackType,
|
||||
forceCategorical?: boolean,
|
||||
dataType?: GenericDataType,
|
||||
): AxisType {
|
||||
if (forceCategorical) {
|
||||
return AxisType.category;
|
||||
}
|
||||
if (dataType === GenericDataType.TEMPORAL) {
|
||||
return AxisType.time;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user