@finos/legend-query-builder 4.14.51 → 4.14.52
Sign up to get free protection for your applications and to get access to all the features.
- package/lib/components/QueryBuilderConstantExpressionPanel.js +1 -1
- package/lib/components/QueryBuilderConstantExpressionPanel.js.map +1 -1
- package/lib/components/QueryBuilderParametersPanel.js +1 -1
- package/lib/components/QueryBuilderParametersPanel.js.map +1 -1
- package/lib/components/QueryBuilderPropertyExpressionEditor.js +1 -1
- package/lib/components/QueryBuilderPropertyExpressionEditor.js.map +1 -1
- package/lib/components/QueryBuilderSideBar.d.ts.map +1 -1
- package/lib/components/QueryBuilderSideBar.js +1 -1
- package/lib/components/QueryBuilderSideBar.js.map +1 -1
- package/lib/components/QueryBuilder_LegendApplicationPlugin.d.ts +0 -1
- package/lib/components/QueryBuilder_LegendApplicationPlugin.d.ts.map +1 -1
- package/lib/components/ServiceQuerySetupUtils.d.ts.map +1 -1
- package/lib/components/__test-utils__/QueryBuilderComponentTestUtils.d.ts +1 -1
- package/lib/components/__test-utils__/QueryBuilderComponentTestUtils.d.ts.map +1 -1
- package/lib/components/__test-utils__/QueryBuilderComponentTestUtils.js +4 -2
- package/lib/components/__test-utils__/QueryBuilderComponentTestUtils.js.map +1 -1
- package/lib/components/execution-plan/AllocationExecutionNodeViewer.d.ts +0 -1
- package/lib/components/execution-plan/AllocationExecutionNodeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/ConstantExecutionNodeViewer.d.ts +0 -1
- package/lib/components/execution-plan/ConstantExecutionNodeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/DataTypeResultTypeViewer.d.ts +0 -1
- package/lib/components/execution-plan/DataTypeResultTypeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/ExecutionPlanViewer.d.ts +0 -1
- package/lib/components/execution-plan/ExecutionPlanViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/FunctionParametersValidationNodeViewer.js +1 -1
- package/lib/components/execution-plan/ImplementationViewer.d.ts +0 -1
- package/lib/components/execution-plan/ImplementationViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/PartialClassResultViewer.d.ts +0 -1
- package/lib/components/execution-plan/PartialClassResultViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/PartialClassResultViewer.js +1 -1
- package/lib/components/execution-plan/RelationalClassQueryTempTableGraphFetchExecutionNodeViewer.d.ts +0 -1
- package/lib/components/execution-plan/RelationalClassQueryTempTableGraphFetchExecutionNodeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/RelationalClassQueryTempTableGraphFetchExecutionNodeViewer.js +1 -1
- package/lib/components/execution-plan/RelationalCrossRootQueryTempTableGraphFetchExecutionNodeViewer.d.ts +0 -1
- package/lib/components/execution-plan/RelationalCrossRootQueryTempTableGraphFetchExecutionNodeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/RelationalCrossRootQueryTempTableGraphFetchExecutionNodeViewer.js +1 -1
- package/lib/components/execution-plan/RelationalRootQueryTempTableGraphFetchExecutionNodeViewer.d.ts +0 -1
- package/lib/components/execution-plan/RelationalRootQueryTempTableGraphFetchExecutionNodeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/RelationalRootQueryTempTableGraphFetchExecutionNodeViewer.js +1 -1
- package/lib/components/execution-plan/RelationalTDSInstantiationExecutionNodeViewer.d.ts +0 -1
- package/lib/components/execution-plan/RelationalTDSInstantiationExecutionNodeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/ResultTypeViewer.d.ts +0 -1
- package/lib/components/execution-plan/ResultTypeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/SQLExecutionNodeViewer.d.ts +0 -1
- package/lib/components/execution-plan/SQLExecutionNodeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/SQLExecutionNodeViewer.js +1 -1
- package/lib/components/execution-plan/SequenceExecutionNodeViewer.d.ts +0 -1
- package/lib/components/execution-plan/SequenceExecutionNodeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/StoreMappingGlobalGraphFetchExecutionNodeViewer.d.ts +0 -1
- package/lib/components/execution-plan/StoreMappingGlobalGraphFetchExecutionNodeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/StoreMappingGlobalGraphFetchExecutionNodeViewer.js +2 -2
- package/lib/components/execution-plan/TDSResultTypeViewer.d.ts +0 -1
- package/lib/components/execution-plan/TDSResultTypeViewer.d.ts.map +1 -1
- package/lib/components/execution-plan/TDSResultTypeViewer.js +1 -1
- package/lib/components/execution-plan/TempTableStrategyViewer.d.ts +0 -1
- package/lib/components/execution-plan/TempTableStrategyViewer.d.ts.map +1 -1
- package/lib/components/explorer/QueryBuilderExplorerPanel.d.ts +0 -1
- package/lib/components/explorer/QueryBuilderExplorerPanel.d.ts.map +1 -1
- package/lib/components/explorer/QueryBuilderMilestoningParameterEditor.js +1 -1
- package/lib/components/explorer/QueryBuilderMilestoningParameterEditor.js.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderGraphFetchTreePanel.d.ts +0 -1
- package/lib/components/fetch-structure/QueryBuilderGraphFetchTreePanel.d.ts.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderPostFilterPanel.d.ts.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderPostFilterPanel.js +1 -1
- package/lib/components/fetch-structure/QueryBuilderPostFilterPanel.js.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderResultModifierPanel.js +1 -1
- package/lib/components/fetch-structure/QueryBuilderResultModifierPanel.js.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderTDSComponentHelper.d.ts +0 -1
- package/lib/components/fetch-structure/QueryBuilderTDSComponentHelper.d.ts.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderTDSPanel.js +1 -1
- package/lib/components/fetch-structure/QueryBuilderTDSPanel.js.map +1 -1
- package/lib/components/filter/QueryBuilderFilterPanel.d.ts.map +1 -1
- package/lib/components/filter/QueryBuilderFilterPanel.js +9 -4
- package/lib/components/filter/QueryBuilderFilterPanel.js.map +1 -1
- package/lib/components/result/QueryBuilderResultPanel.d.ts.map +1 -1
- package/lib/components/result/QueryBuilderResultPanel.js +1 -1
- package/lib/components/result/QueryBuilderResultPanel.js.map +1 -1
- package/lib/components/result/tds/QueryBuilderTDSGridResult.d.ts.map +1 -1
- package/lib/components/result/tds/QueryBuilderTDSGridResult.js +10 -8
- package/lib/components/result/tds/QueryBuilderTDSGridResult.js.map +1 -1
- package/lib/components/result/tds/QueryBuilderTDSResultShared.d.ts +0 -1
- package/lib/components/result/tds/QueryBuilderTDSResultShared.d.ts.map +1 -1
- package/lib/components/result/tds/QueryBuilderTDSResultShared.js.map +1 -1
- package/lib/components/result/tds/QueryBuilderTDSSimpleGridResult.js +2 -2
- package/lib/components/result/tds/QueryBuilderTDSSimpleGridResult.js.map +1 -1
- package/lib/components/shared/BasicValueSpecificationEditor.d.ts +19 -4
- package/lib/components/shared/BasicValueSpecificationEditor.d.ts.map +1 -1
- package/lib/components/shared/BasicValueSpecificationEditor.js +97 -36
- package/lib/components/shared/BasicValueSpecificationEditor.js.map +1 -1
- package/lib/components/shared/CustomDatePicker.d.ts +2 -1
- package/lib/components/shared/CustomDatePicker.d.ts.map +1 -1
- package/lib/components/shared/CustomDatePicker.js +8 -5
- package/lib/components/shared/CustomDatePicker.js.map +1 -1
- package/lib/components/shared/LambdaParameterValuesEditor.js +1 -1
- package/lib/components/shared/LambdaParameterValuesEditor.js.map +1 -1
- package/lib/components/shared/QueryBuilderPanelIssueCountBadge.d.ts +0 -1
- package/lib/components/shared/QueryBuilderPanelIssueCountBadge.d.ts.map +1 -1
- package/lib/components/shared/QueryBuilderPropertyInfoTooltip.d.ts +0 -1
- package/lib/components/shared/QueryBuilderPropertyInfoTooltip.d.ts.map +1 -1
- package/lib/components/shared/QueryBuilderRootClassInfoTooltip.d.ts +0 -1
- package/lib/components/shared/QueryBuilderRootClassInfoTooltip.d.ts.map +1 -1
- package/lib/components/shared/QueryBuilderVariableSelector.d.ts.map +1 -1
- package/lib/components/shared/QueryBuilderVariableSelector.js +1 -1
- package/lib/components/shared/QueryBuilderVariableSelector.js.map +1 -1
- package/lib/components/workflows/ClassQueryBuilder.d.ts.map +1 -1
- package/lib/components/workflows/MappingQueryBuilder.d.ts.map +1 -1
- package/lib/components/workflows/ServiceQueryBuilder.d.ts.map +1 -1
- package/lib/graph/QueryBuilderMetaModelConst.d.ts +1 -0
- package/lib/graph/QueryBuilderMetaModelConst.d.ts.map +1 -1
- package/lib/graph/QueryBuilderMetaModelConst.js +1 -0
- package/lib/graph/QueryBuilderMetaModelConst.js.map +1 -1
- package/lib/graph-manager/protocol/pure/QueryBuilder_PureGraphManagerExtension.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/QueryBuilder_PureGraphManagerExtension.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.d.ts +1 -2
- package/lib/graph-manager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.js +68 -8
- package/lib/graph-manager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.js.map +1 -1
- package/lib/index.css +2 -2
- package/lib/index.css.map +1 -1
- package/lib/package.json +7 -7
- package/lib/stores/QueryBuilderState.d.ts +0 -1
- package/lib/stores/QueryBuilderState.d.ts.map +1 -1
- package/lib/stores/QueryBuilderStateBuilder.d.ts.map +1 -1
- package/lib/stores/QueryBuilderStateBuilder.js +5 -1
- package/lib/stores/QueryBuilderStateBuilder.js.map +1 -1
- package/lib/stores/QueryBuilderValueSpecificationHelper.js.map +1 -1
- package/lib/stores/QueryBuilder_LegendApplicationPlugin_Extension.d.ts +0 -1
- package/lib/stores/QueryBuilder_LegendApplicationPlugin_Extension.d.ts.map +1 -1
- package/lib/stores/__test-utils__/QueryBuilderStateTestUtils.d.ts.map +1 -1
- package/lib/stores/execution-plan/ExecutionPlanState.d.ts.map +1 -1
- package/lib/stores/explorer/QueryBuilderExplorerState.d.ts +0 -1
- package/lib/stores/explorer/QueryBuilderExplorerState.d.ts.map +1 -1
- package/lib/stores/explorer/QueryFunctionsExplorerState.d.ts.map +1 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeUtil.d.ts.map +1 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeValueSpecificationBuilder.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSState.d.ts +2 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSState.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSState.js +6 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSState.js.map +1 -1
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionStateBuilder.d.ts +11 -0
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionStateBuilder.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionStateBuilder.js +76 -20
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionStateBuilder.js.map +1 -1
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionValueSpecificationBuilder.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionValueSpecificationBuilder.js +70 -34
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionValueSpecificationBuilder.js.map +1 -1
- package/lib/stores/filter/QueryBuilderFilterState.d.ts +2 -0
- package/lib/stores/filter/QueryBuilderFilterState.d.ts.map +1 -1
- package/lib/stores/filter/QueryBuilderFilterState.js +7 -0
- package/lib/stores/filter/QueryBuilderFilterState.js.map +1 -1
- package/lib/stores/shared/ValueSpecificationEditorHelper.d.ts +5 -2
- package/lib/stores/shared/ValueSpecificationEditorHelper.d.ts.map +1 -1
- package/lib/stores/shared/ValueSpecificationEditorHelper.js +20 -9
- package/lib/stores/shared/ValueSpecificationEditorHelper.js.map +1 -1
- package/lib/stores/shared/ValueSpecificationModifierHelper.d.ts.map +1 -1
- package/lib/stores/workflows/ClassQueryBuilderState.d.ts.map +1 -1
- package/lib/stores/workflows/MappingQueryBuilderState.d.ts.map +1 -1
- package/lib/stores/workflows/ServiceQueryBuilderState.d.ts.map +1 -1
- package/package.json +15 -15
- package/src/components/QueryBuilderConstantExpressionPanel.tsx +1 -1
- package/src/components/QueryBuilderParametersPanel.tsx +1 -1
- package/src/components/QueryBuilderPropertyExpressionEditor.tsx +1 -1
- package/src/components/QueryBuilderSideBar.tsx +1 -1
- package/src/components/__test-utils__/QueryBuilderComponentTestUtils.tsx +4 -1
- package/src/components/execution-plan/FunctionParametersValidationNodeViewer.tsx +1 -1
- package/src/components/execution-plan/PartialClassResultViewer.tsx +1 -1
- package/src/components/execution-plan/RelationalClassQueryTempTableGraphFetchExecutionNodeViewer.tsx +1 -1
- package/src/components/execution-plan/RelationalCrossRootQueryTempTableGraphFetchExecutionNodeViewer.tsx +1 -1
- package/src/components/execution-plan/RelationalRootQueryTempTableGraphFetchExecutionNodeViewer.tsx +1 -1
- package/src/components/execution-plan/SQLExecutionNodeViewer.tsx +1 -1
- package/src/components/execution-plan/StoreMappingGlobalGraphFetchExecutionNodeViewer.tsx +2 -2
- package/src/components/execution-plan/TDSResultTypeViewer.tsx +1 -1
- package/src/components/explorer/QueryBuilderMilestoningParameterEditor.tsx +1 -1
- package/src/components/fetch-structure/QueryBuilderPostFilterPanel.tsx +1 -1
- package/src/components/fetch-structure/QueryBuilderResultModifierPanel.tsx +1 -1
- package/src/components/fetch-structure/QueryBuilderTDSPanel.tsx +1 -1
- package/src/components/filter/QueryBuilderFilterPanel.tsx +18 -4
- package/src/components/result/QueryBuilderResultPanel.tsx +1 -0
- package/src/components/result/tds/QueryBuilderTDSGridResult.tsx +12 -13
- package/src/components/result/tds/QueryBuilderTDSResultShared.tsx +1 -1
- package/src/components/result/tds/QueryBuilderTDSSimpleGridResult.tsx +2 -2
- package/src/components/shared/BasicValueSpecificationEditor.tsx +257 -55
- package/src/components/shared/CustomDatePicker.tsx +36 -11
- package/src/components/shared/LambdaParameterValuesEditor.tsx +1 -1
- package/src/components/shared/QueryBuilderVariableSelector.tsx +4 -1
- package/src/graph/QueryBuilderMetaModelConst.ts +1 -0
- package/src/graph-manager/protocol/pure/QueryBuilder_PureGraphManagerExtension.ts +1 -1
- package/src/graph-manager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.ts +189 -18
- package/src/stores/QueryBuilderStateBuilder.ts +6 -1
- package/src/stores/QueryBuilderValueSpecificationHelper.ts +2 -2
- package/src/stores/fetch-structure/tds/QueryBuilderTDSState.ts +7 -0
- package/src/stores/fetch-structure/tds/projection/QueryBuilderProjectionStateBuilder.ts +167 -43
- package/src/stores/fetch-structure/tds/projection/QueryBuilderProjectionValueSpecificationBuilder.ts +145 -69
- package/src/stores/filter/QueryBuilderFilterState.ts +8 -0
- package/src/stores/shared/ValueSpecificationEditorHelper.ts +47 -7
- package/tsconfig.package.json +1 -1
@@ -14,7 +14,14 @@
|
|
14
14
|
* limitations under the License.
|
15
15
|
*/
|
16
16
|
|
17
|
-
import {
|
17
|
+
import {
|
18
|
+
useRef,
|
19
|
+
useState,
|
20
|
+
useCallback,
|
21
|
+
forwardRef,
|
22
|
+
useMemo,
|
23
|
+
useEffect,
|
24
|
+
} from 'react';
|
18
25
|
import { observer } from 'mobx-react-lite';
|
19
26
|
import {
|
20
27
|
type TreeNodeContainerProps,
|
@@ -103,9 +110,9 @@ import type { QueryBuilderFilterOperator } from '../../stores/filter/QueryBuilde
|
|
103
110
|
import { isTypeCompatibleForAssignment } from '../../stores/QueryBuilderValueSpecificationHelper.js';
|
104
111
|
import { QUERY_BUILDER_GROUP_OPERATION } from '../../stores/QueryBuilderGroupOperationHelper.js';
|
105
112
|
import {
|
106
|
-
BasicValueSpecificationEditor,
|
107
113
|
type QueryBuilderVariableDragSource,
|
108
114
|
QUERY_BUILDER_VARIABLE_DND_TYPE,
|
115
|
+
EditableBasicValueSpecificationEditor,
|
109
116
|
} from '../shared/BasicValueSpecificationEditor.js';
|
110
117
|
import { QueryBuilderTelemetryHelper } from '../../__lib__/QueryBuilderTelemetryHelper.js';
|
111
118
|
import { getPropertyChainName } from '../../stores/QueryBuilderPropertyEditorState.js';
|
@@ -350,6 +357,7 @@ export const buildFilterTreeWithExists = (
|
|
350
357
|
undefined,
|
351
358
|
filterConditionState,
|
352
359
|
);
|
360
|
+
treeNode.setIsNewlyAdded(true);
|
353
361
|
filterState.addNodeFromNode(treeNode, parentNode);
|
354
362
|
if (targetDropNode instanceof QueryBuilderFilterTreeBlankConditionNodeData) {
|
355
363
|
filterState.removeNodeAndPruneBranch(targetDropNode);
|
@@ -511,6 +519,7 @@ const buildFilterTree = (
|
|
511
519
|
undefined,
|
512
520
|
filterConditionState,
|
513
521
|
);
|
522
|
+
treeNode.setIsNewlyAdded(true);
|
514
523
|
// Check if there are any exists node present in the parent nodes of the target.
|
515
524
|
// This would change the way we build the filter tree
|
516
525
|
let cn: QueryBuilderFilterTreeNodeData | undefined = targetDropNode;
|
@@ -798,6 +807,10 @@ const QueryBuilderFilterConditionEditor = observer(
|
|
798
807
|
cleanUpReloadValues,
|
799
808
|
};
|
800
809
|
|
810
|
+
useEffect(() => {
|
811
|
+
node.setIsNewlyAdded(false);
|
812
|
+
}, [node]);
|
813
|
+
|
801
814
|
return (
|
802
815
|
<div
|
803
816
|
className="dnd__entry__container"
|
@@ -856,11 +869,11 @@ const QueryBuilderFilterConditionEditor = observer(
|
|
856
869
|
isDragOver={isFilterValueDragOver}
|
857
870
|
label="Change Filter Value"
|
858
871
|
>
|
859
|
-
<
|
872
|
+
<EditableBasicValueSpecificationEditor
|
860
873
|
valueSpecification={node.condition.value}
|
861
874
|
setValueSpecification={changeValueSpecification}
|
862
875
|
graph={graph}
|
863
|
-
|
876
|
+
observerContext={queryBuilderState.observerContext}
|
864
877
|
typeCheckOption={{
|
865
878
|
expectedType:
|
866
879
|
node.condition.propertyExpressionState
|
@@ -872,6 +885,7 @@ const QueryBuilderFilterConditionEditor = observer(
|
|
872
885
|
isConstant={queryBuilderState.constantState.isValueSpecConstant(
|
873
886
|
node.condition.value,
|
874
887
|
)}
|
888
|
+
initializeAsEditable={node.isNewlyAdded}
|
875
889
|
/>
|
876
890
|
</PanelEntryDropZonePlaceholder>
|
877
891
|
</div>
|
@@ -22,7 +22,6 @@ import {
|
|
22
22
|
DataGrid,
|
23
23
|
type DataGridApi,
|
24
24
|
type DataGridCellRange,
|
25
|
-
type DataGridColumnApi,
|
26
25
|
type DataGridColumnDefinition,
|
27
26
|
type DataGridGetContextMenuItemsParams,
|
28
27
|
type DataGridIRowNode,
|
@@ -249,9 +248,7 @@ export const QueryBuilderTDSGridResult = observer(
|
|
249
248
|
const applicationStore = useApplicationStore();
|
250
249
|
const darkMode =
|
251
250
|
!applicationStore.layoutService.TEMPORARY__isLightColorThemeEnabled;
|
252
|
-
const [
|
253
|
-
undefined,
|
254
|
-
);
|
251
|
+
const [gridApi, setGridApi] = useState<DataGridApi | undefined>(undefined);
|
255
252
|
const [aggFuncParams, setAggFuncParams] = useState<
|
256
253
|
DataGridIAggFuncParams | undefined
|
257
254
|
>(undefined);
|
@@ -262,12 +259,12 @@ export const QueryBuilderTDSGridResult = observer(
|
|
262
259
|
: getColDefs(executionResult, resultState);
|
263
260
|
|
264
261
|
const onSaveGridColumnState = (): void => {
|
265
|
-
if (!
|
262
|
+
if (!gridApi) {
|
266
263
|
return;
|
267
264
|
}
|
268
265
|
resultState.setGridConfig({
|
269
|
-
columns:
|
270
|
-
isPivotModeEnabled:
|
266
|
+
columns: gridApi.getColumnState(),
|
267
|
+
isPivotModeEnabled: gridApi.isPivotMode(),
|
271
268
|
isLocalModeEnabled: true,
|
272
269
|
previewLimit: resultState.previewLimit,
|
273
270
|
...(resultState.wavgAggregationState?.weightedColumnIdPairs && {
|
@@ -368,7 +365,7 @@ export const QueryBuilderTDSGridResult = observer(
|
|
368
365
|
],
|
369
366
|
);
|
370
367
|
|
371
|
-
const weightedColumnOptions =
|
368
|
+
const weightedColumnOptions = gridApi
|
372
369
|
?.getColumns()
|
373
370
|
?.filter((c) => c.getColDef().cellDataType === 'number')
|
374
371
|
.map((col) => ({
|
@@ -458,7 +455,7 @@ export const QueryBuilderTDSGridResult = observer(
|
|
458
455
|
|
459
456
|
useEffect(() => {
|
460
457
|
if (aggFuncParams) {
|
461
|
-
aggFuncParams.
|
458
|
+
aggFuncParams.api.setColumnAggFunc(
|
462
459
|
aggFuncParams.colDef.field!,
|
463
460
|
QueryBuilderDataGridCustomAggregationFunction.WAVG,
|
464
461
|
);
|
@@ -480,10 +477,12 @@ export const QueryBuilderTDSGridResult = observer(
|
|
480
477
|
<DataGrid
|
481
478
|
rowData={getRowDataFromExecutionResult(executionResult)}
|
482
479
|
onGridReady={(params): void => {
|
483
|
-
|
484
|
-
params.
|
485
|
-
Boolean(
|
486
|
-
|
480
|
+
setGridApi(params.api);
|
481
|
+
params.api.updateGridOptions({
|
482
|
+
pivotMode: Boolean(
|
483
|
+
resultState.gridConfig?.isPivotModeEnabled,
|
484
|
+
),
|
485
|
+
});
|
487
486
|
}}
|
488
487
|
gridOptions={{
|
489
488
|
suppressScrollOnNewData: true,
|
@@ -316,7 +316,7 @@ const updateExistingPostFilterConditionNodeData = (
|
|
316
316
|
.map((v) =>
|
317
317
|
v instanceof EnumValueInstanceValue
|
318
318
|
? v.values.map((ef) => ef.value.name)
|
319
|
-
:
|
319
|
+
: v.values,
|
320
320
|
)
|
321
321
|
.flat()
|
322
322
|
.includes(_cellData.value ?? data?.value);
|
@@ -114,11 +114,11 @@ const QueryResultCellRenderer = observer(
|
|
114
114
|
) {
|
115
115
|
return undefined;
|
116
116
|
}
|
117
|
-
if (params.
|
117
|
+
if (params.api.getColumnState()[colIndex]?.sort === 'asc') {
|
118
118
|
resultState.executionResult.result.rows.sort((a, b) =>
|
119
119
|
getTDSRowRankByColumnInAsc(a, b, colIndex),
|
120
120
|
);
|
121
|
-
} else if (params.
|
121
|
+
} else if (params.api.getColumnState()[colIndex]?.sort === 'desc') {
|
122
122
|
resultState.executionResult.result.rows.sort((a, b) =>
|
123
123
|
getTDSRowRankByColumnInAsc(b, a, colIndex),
|
124
124
|
);
|