@lightdash/common 0.1378.4 → 0.1379.0
Sign up to get free protection for your applications and to get access to all the features.
package/dist/types/catalog.d.ts
CHANGED
@@ -62,6 +62,10 @@ export type ApiMetricsCatalog = {
|
|
62
62
|
status: 'ok';
|
63
63
|
results: KnexPaginatedData<ApiMetricsCatalogResults>;
|
64
64
|
};
|
65
|
+
export type ApiGetMetric = {
|
66
|
+
status: 'ok';
|
67
|
+
results: CompiledMetric;
|
68
|
+
};
|
65
69
|
export type CatalogMetadata = {
|
66
70
|
name: string;
|
67
71
|
description: string | undefined;
|
@@ -90,9 +90,9 @@ class CartesianChartDataModel {
|
|
90
90
|
[field_1.DimensionType.DATE, field_1.DimensionType.TIMESTAMP].includes(column.dimensionType));
|
91
91
|
const numericColumns = [...dimensions, ...metrics].filter((column) => 'dimensionType' in column &&
|
92
92
|
column.dimensionType === field_1.DimensionType.NUMBER);
|
93
|
-
const xColumn =
|
93
|
+
const xColumn = dateColumns[0] ||
|
94
|
+
categoricalColumns[0] ||
|
94
95
|
booleanColumns[0] ||
|
95
|
-
dateColumns[0] ||
|
96
96
|
numericColumns[0] ||
|
97
97
|
dimensions[0];
|
98
98
|
if (xColumn === undefined) {
|