@finos/legend-query-builder 0.1.2 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- package/lib/components/QueryBuilder.d.ts.map +1 -1
- package/lib/components/QueryBuilder.js +1 -1
- package/lib/components/QueryBuilder.js.map +1 -1
- package/lib/components/QueryBuilderComponentTestUtils.d.ts.map +1 -1
- package/lib/components/QueryBuilderComponentTestUtils.js +1 -3
- package/lib/components/QueryBuilderComponentTestUtils.js.map +1 -1
- package/lib/components/QueryBuilderDiffPanel.js +1 -2
- package/lib/components/QueryBuilderDiffPanel.js.map +1 -1
- package/lib/components/QueryBuilderParametersPanel.d.ts +1 -1
- package/lib/components/QueryBuilderParametersPanel.d.ts.map +1 -1
- package/lib/components/QueryBuilderParametersPanel.js +8 -5
- package/lib/components/QueryBuilderParametersPanel.js.map +1 -1
- package/lib/components/QueryBuilderPropertyExpressionEditor.d.ts.map +1 -1
- package/lib/components/QueryBuilderPropertyExpressionEditor.js +11 -8
- package/lib/components/QueryBuilderPropertyExpressionEditor.js.map +1 -1
- package/lib/components/QueryBuilderResultPanel.d.ts.map +1 -1
- package/lib/components/QueryBuilderResultPanel.js +6 -4
- package/lib/components/QueryBuilderResultPanel.js.map +1 -1
- package/lib/components/QueryBuilderTextEditor.js +2 -2
- package/lib/components/QueryBuilderTextEditor.js.map +1 -1
- package/lib/components/QueryBuilder_TestID.d.ts +1 -0
- package/lib/components/QueryBuilder_TestID.d.ts.map +1 -1
- package/lib/components/QueryBuilder_TestID.js +1 -0
- package/lib/components/QueryBuilder_TestID.js.map +1 -1
- package/lib/components/explorer/QueryBuilderExplorerPanel.js +2 -2
- package/lib/components/explorer/QueryBuilderExplorerPanel.js.map +1 -1
- package/lib/components/explorer/QueryBuilderMilestoningEditor.d.ts.map +1 -1
- package/lib/components/explorer/QueryBuilderMilestoningEditor.js +5 -4
- package/lib/components/explorer/QueryBuilderMilestoningEditor.js.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderPostFilterPanel.d.ts.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderPostFilterPanel.js +4 -2
- 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/filter/QueryBuilderFilterPanel.d.ts.map +1 -1
- package/lib/components/filter/QueryBuilderFilterPanel.js +7 -4
- package/lib/components/filter/QueryBuilderFilterPanel.js.map +1 -1
- package/lib/components/shared/BasicValueSpecificationEditor.d.ts +53 -0
- package/lib/components/shared/BasicValueSpecificationEditor.d.ts.map +1 -0
- package/lib/components/shared/BasicValueSpecificationEditor.js +323 -0
- package/lib/components/shared/BasicValueSpecificationEditor.js.map +1 -0
- package/lib/components/shared/CustomDatePicker.d.ts +39 -0
- package/lib/components/shared/CustomDatePicker.d.ts.map +1 -0
- package/lib/components/shared/CustomDatePicker.js +622 -0
- package/lib/components/shared/CustomDatePicker.js.map +1 -0
- package/lib/components/shared/LambdaEditor.d.ts +92 -0
- package/lib/components/shared/LambdaEditor.d.ts.map +1 -0
- package/lib/components/shared/LambdaEditor.js +432 -0
- package/lib/components/shared/LambdaEditor.js.map +1 -0
- package/lib/{graphManager/protocol/pure/v1/V1_QueryBuilder_PropertyExpressionTypeInferenceBuilder.d.ts → components/shared/LambdaParameterValuesEditor.d.ts} +11 -3
- package/lib/components/shared/LambdaParameterValuesEditor.d.ts.map +1 -0
- package/lib/components/shared/LambdaParameterValuesEditor.js +52 -0
- package/lib/components/shared/LambdaParameterValuesEditor.js.map +1 -0
- package/lib/components/shared/QueryBuilderLambdaEditor.d.ts +1 -1
- package/lib/components/shared/QueryBuilderLambdaEditor.d.ts.map +1 -1
- package/lib/components/shared/QueryBuilderLambdaEditor.js +3 -2
- package/lib/components/shared/QueryBuilderLambdaEditor.js.map +1 -1
- package/lib/graphManager/protocol/pure/QueryBuilder_PureProtocolProcessorPlugin.d.ts.map +1 -1
- package/lib/graphManager/protocol/pure/QueryBuilder_PureProtocolProcessorPlugin.js +1 -2
- package/lib/graphManager/protocol/pure/QueryBuilder_PureProtocolProcessorPlugin.js.map +1 -1
- package/lib/graphManager/protocol/pure/v1/{V1_QueryBuilder_FunctionExpressionBuilder.d.ts → V1_QueryValueSpecificationBuilderHelper.d.ts} +3 -2
- package/lib/graphManager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.d.ts.map +1 -0
- package/lib/graphManager/protocol/pure/v1/{V1_QueryBuilder_FunctionExpressionBuilder.js → V1_QueryValueSpecificationBuilderHelper.js} +3 -2
- package/lib/graphManager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.js.map +1 -0
- package/lib/index.css +2 -2
- package/lib/index.css.map +1 -1
- package/lib/index.d.ts +7 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +8 -0
- package/lib/index.js.map +1 -1
- package/lib/package.json +7 -10
- package/lib/stores/QueryBuilderMilestoningState.d.ts.map +1 -1
- package/lib/stores/QueryBuilderMilestoningState.js +6 -6
- package/lib/stores/QueryBuilderMilestoningState.js.map +1 -1
- package/lib/stores/QueryBuilderParametersState.d.ts +1 -1
- package/lib/stores/QueryBuilderParametersState.d.ts.map +1 -1
- package/lib/stores/QueryBuilderParametersState.js +1 -1
- package/lib/stores/QueryBuilderParametersState.js.map +1 -1
- package/lib/stores/QueryBuilderPropertyEditorState.d.ts.map +1 -1
- package/lib/stores/QueryBuilderPropertyEditorState.js +35 -38
- package/lib/stores/QueryBuilderPropertyEditorState.js.map +1 -1
- package/lib/stores/QueryBuilderResultState.d.ts.map +1 -1
- package/lib/stores/QueryBuilderResultState.js +2 -1
- package/lib/stores/QueryBuilderResultState.js.map +1 -1
- package/lib/stores/QueryBuilderState.d.ts +2 -2
- package/lib/stores/QueryBuilderState.d.ts.map +1 -1
- package/lib/stores/QueryBuilderState.js +5 -5
- package/lib/stores/QueryBuilderState.js.map +1 -1
- package/lib/stores/QueryBuilderStateBuilder.js +1 -1
- package/lib/stores/QueryBuilderStateBuilder.js.map +1 -1
- package/lib/stores/QueryBuilderTextEditorState.d.ts +1 -1
- package/lib/stores/QueryBuilderTextEditorState.d.ts.map +1 -1
- package/lib/stores/QueryBuilderTextEditorState.js +2 -1
- package/lib/stores/QueryBuilderTextEditorState.js.map +1 -1
- package/lib/stores/QueryBuilderValueSpecificationBuilder.d.ts.map +1 -1
- package/lib/stores/QueryBuilderValueSpecificationBuilder.js +2 -2
- package/lib/stores/QueryBuilderValueSpecificationBuilder.js.map +1 -1
- package/lib/stores/QueryBuilderValueSpecificationBuilderHelper.d.ts.map +1 -1
- package/lib/stores/QueryBuilderValueSpecificationBuilderHelper.js +23 -20
- package/lib/stores/QueryBuilderValueSpecificationBuilderHelper.js.map +1 -1
- package/lib/stores/QueryBuilderValueSpecificationHelper.d.ts +1 -1
- package/lib/stores/QueryBuilderValueSpecificationHelper.d.ts.map +1 -1
- package/lib/stores/QueryBuilderValueSpecificationHelper.js +10 -9
- package/lib/stores/QueryBuilderValueSpecificationHelper.js.map +1 -1
- package/lib/stores/explorer/QueryBuilderExplorerState.d.ts.map +1 -1
- package/lib/stores/explorer/QueryBuilderExplorerState.js +4 -3
- package/lib/stores/explorer/QueryBuilderExplorerState.js.map +1 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeState.js +1 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeState.js.map +1 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeUtil.js +1 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeUtil.js.map +1 -1
- package/lib/stores/fetch-structure/graph-fetch/{QueryBuilderGraphFetchValueSpecificationBuilder.d.ts → QueryBuilderGraphFetchTreeValueSpecificationBuilder.d.ts} +1 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeValueSpecificationBuilder.d.ts.map +1 -0
- package/lib/stores/fetch-structure/graph-fetch/{QueryBuilderGraphFetchValueSpecificationBuilder.js → QueryBuilderGraphFetchTreeValueSpecificationBuilder.js} +1 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeValueSpecificationBuilder.js.map +1 -0
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionColumnState.d.ts +1 -1
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionColumnState.d.ts.map +1 -1
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionColumnState.js +3 -3
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionColumnState.js.map +1 -1
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionState.js +1 -1
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionState.js.map +1 -1
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionStateBuilder.js +4 -4
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionStateBuilder.js.map +1 -1
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionValueSpecificationBuilder.d.ts.map +1 -1
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionValueSpecificationBuilder.js +6 -6
- package/lib/stores/fetch-structure/projection/QueryBuilderProjectionValueSpecificationBuilder.js.map +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/{QueryBuilderAggregateOperatorHelper.d.ts → QueryBuilderAggregateOperatorValueSpecificationBuilder.d.ts} +2 -2
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperatorValueSpecificationBuilder.d.ts.map +1 -0
- package/lib/stores/fetch-structure/projection/aggregation/operators/{QueryBuilderAggregateOperatorHelper.js → QueryBuilderAggregateOperatorValueSpecificationBuilder.js} +2 -2
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperatorValueSpecificationBuilder.js.map +1 -0
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Average.js +3 -3
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Average.js.map +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Count.js +3 -3
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Count.js.map +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Distinct.js +3 -3
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Distinct.js.map +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_DistinctCount.js +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_DistinctCount.js.map +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_JoinString.js +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_JoinString.js.map +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Max.js +5 -5
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Max.js.map +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Min.js +5 -5
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Min.js.map +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_StdDev_Population.js +3 -3
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_StdDev_Population.js.map +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_StdDev_Sample.js +3 -3
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_StdDev_Sample.js.map +1 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Sum.js +3 -3
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Sum.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/QueryBuilderPostFilterStateBuilder.js +2 -2
- package/lib/stores/fetch-structure/projection/post-filter/QueryBuilderPostFilterStateBuilder.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/QueryBuilderPostFilterValueSpecificationBuilder.d.ts +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/QueryBuilderPostFilterValueSpecificationBuilder.d.ts.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/QueryBuilderPostFilterValueSpecificationBuilder.js +10 -10
- package/lib/stores/fetch-structure/projection/post-filter/QueryBuilderPostFilterValueSpecificationBuilder.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperatorHelper.d.ts +1 -4
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperatorHelper.d.ts.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperatorHelper.js +3 -46
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperatorHelper.js.map +1 -1
- package/{src/graphManager/protocol/pure/v1/V1_QueryBuilder_PropertyExpressionTypeInferenceBuilder.ts → lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperatorValueSpecificationBuilder.d.ts} +5 -13
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperatorValueSpecificationBuilder.d.ts.map +1 -0
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperatorValueSpecificationBuilder.js +61 -0
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperatorValueSpecificationBuilder.js.map +1 -0
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_Contain.d.ts.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_Contain.js +5 -4
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_Contain.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_EndWith.d.ts.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_EndWith.js +5 -4
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_EndWith.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_Equal.d.ts.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_Equal.js +10 -8
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_Equal.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThan.d.ts.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThan.js +5 -4
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThan.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThanEqual.js +3 -3
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThanEqual.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_In.js +3 -3
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_In.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_IsEmpty.js +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_IsEmpty.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_LessThan.d.ts.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_LessThan.js +5 -4
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_LessThan.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_LessThanEqual.js +3 -3
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_LessThanEqual.js.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_StartWith.d.ts.map +1 -1
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_StartWith.js +5 -4
- package/lib/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_StartWith.js.map +1 -1
- package/lib/stores/filter/operators/{QueryBuilderFilterOperatorHelper.d.ts → QueryBuilderFilterOperatorValueSpecificationBuilder.d.ts} +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperatorValueSpecificationBuilder.d.ts.map +1 -0
- package/lib/stores/filter/operators/{QueryBuilderFilterOperatorHelper.js → QueryBuilderFilterOperatorValueSpecificationBuilder.js} +11 -13
- package/lib/stores/filter/operators/QueryBuilderFilterOperatorValueSpecificationBuilder.js.map +1 -0
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_Contain.d.ts.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_Contain.js +7 -6
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_Contain.js.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_EndWith.d.ts.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_EndWith.js +7 -6
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_EndWith.js.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_Equal.d.ts.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_Equal.js +13 -11
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_Equal.js.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_GreaterThan.d.ts.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_GreaterThan.js +8 -7
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_GreaterThan.js.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_GreaterThanEqual.d.ts.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_GreaterThanEqual.js +8 -7
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_GreaterThanEqual.js.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_In.js +6 -6
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_In.js.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_IsEmpty.js +4 -4
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_IsEmpty.js.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_LessThan.d.ts.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_LessThan.js +8 -7
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_LessThan.js.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_LessThanEqual.d.ts.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_LessThanEqual.js +8 -7
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_LessThanEqual.js.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_StartWith.d.ts.map +1 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_StartWith.js +7 -6
- package/lib/stores/filter/operators/QueryBuilderFilterOperator_StartWith.js.map +1 -1
- package/lib/stores/shared/LambdaEditorState.d.ts +40 -0
- package/lib/stores/shared/LambdaEditorState.d.ts.map +1 -0
- package/lib/stores/shared/LambdaEditorState.js +81 -0
- package/lib/stores/shared/LambdaEditorState.js.map +1 -0
- package/lib/stores/shared/LambdaParameterState.d.ts +62 -0
- package/lib/stores/shared/LambdaParameterState.d.ts.map +1 -0
- package/lib/stores/shared/LambdaParameterState.js +157 -0
- package/lib/stores/shared/LambdaParameterState.js.map +1 -0
- package/lib/{graphManager/protocol/pure/v1/V1_QueryBuilder_PropertyExpressionTypeInferenceBuilder.js → stores/shared/ValueSpecificationEditorHelper.d.ts} +5 -3
- package/lib/stores/shared/ValueSpecificationEditorHelper.d.ts.map +1 -0
- package/lib/stores/shared/ValueSpecificationEditorHelper.js +77 -0
- package/lib/stores/shared/ValueSpecificationEditorHelper.js.map +1 -0
- package/lib/stores/shared/ValueSpecificationModifierHelper.d.ts +33 -0
- package/lib/stores/shared/ValueSpecificationModifierHelper.d.ts.map +1 -0
- package/lib/stores/shared/ValueSpecificationModifierHelper.js +71 -0
- package/lib/stores/shared/ValueSpecificationModifierHelper.js.map +1 -0
- package/package.json +14 -17
- package/src/components/QueryBuilder.tsx +4 -1
- package/src/components/QueryBuilderComponentTestUtils.tsx +2 -2
- package/src/components/QueryBuilderDiffPanel.tsx +1 -1
- package/src/components/QueryBuilderParametersPanel.tsx +8 -7
- package/src/components/QueryBuilderPropertyExpressionEditor.tsx +15 -12
- package/src/components/QueryBuilderResultPanel.tsx +8 -6
- package/src/components/QueryBuilderTextEditor.tsx +2 -2
- package/src/components/QueryBuilder_TestID.ts +2 -0
- package/src/components/explorer/QueryBuilderExplorerPanel.tsx +2 -2
- package/src/components/explorer/QueryBuilderMilestoningEditor.tsx +5 -3
- package/src/components/fetch-structure/QueryBuilderPostFilterPanel.tsx +6 -4
- package/src/components/fetch-structure/QueryBuilderResultModifierPanel.tsx +1 -1
- package/src/components/filter/QueryBuilderFilterPanel.tsx +9 -6
- package/src/components/shared/BasicValueSpecificationEditor.tsx +837 -0
- package/src/components/shared/CustomDatePicker.tsx +1363 -0
- package/src/components/shared/LambdaEditor.tsx +858 -0
- package/src/components/shared/LambdaParameterValuesEditor.tsx +121 -0
- package/src/components/shared/QueryBuilderLambdaEditor.tsx +5 -5
- package/src/graphManager/protocol/pure/QueryBuilder_PureProtocolProcessorPlugin.ts +2 -2
- package/src/graphManager/protocol/pure/v1/{V1_QueryBuilder_FunctionExpressionBuilder.ts → V1_QueryValueSpecificationBuilderHelper.ts} +9 -1
- package/src/index.ts +11 -0
- package/src/stores/QueryBuilderMilestoningState.ts +7 -7
- package/src/stores/QueryBuilderParametersState.ts +4 -4
- package/src/stores/QueryBuilderPropertyEditorState.ts +49 -56
- package/src/stores/QueryBuilderResultState.ts +2 -4
- package/src/stores/QueryBuilderState.ts +5 -5
- package/src/stores/QueryBuilderStateBuilder.ts +1 -1
- package/src/stores/QueryBuilderTextEditorState.ts +2 -1
- package/src/stores/QueryBuilderValueSpecificationBuilder.ts +5 -2
- package/src/stores/QueryBuilderValueSpecificationBuilderHelper.ts +30 -42
- package/src/stores/QueryBuilderValueSpecificationHelper.ts +13 -8
- package/src/stores/explorer/QueryBuilderExplorerState.ts +12 -2
- package/src/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeState.ts +1 -1
- package/src/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeUtil.ts +3 -3
- package/src/stores/fetch-structure/graph-fetch/{QueryBuilderGraphFetchValueSpecificationBuilder.ts → QueryBuilderGraphFetchTreeValueSpecificationBuilder.ts} +0 -1
- package/src/stores/fetch-structure/projection/QueryBuilderProjectionColumnState.ts +3 -3
- package/src/stores/fetch-structure/projection/QueryBuilderProjectionState.ts +1 -1
- package/src/stores/fetch-structure/projection/QueryBuilderProjectionStateBuilder.ts +4 -4
- package/src/stores/fetch-structure/projection/QueryBuilderProjectionValueSpecificationBuilder.ts +6 -9
- package/src/stores/fetch-structure/projection/aggregation/operators/{QueryBuilderAggregateOperatorHelper.ts → QueryBuilderAggregateOperatorValueSpecificationBuilder.ts} +1 -1
- package/src/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Average.ts +3 -3
- package/src/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Count.ts +3 -3
- package/src/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Distinct.ts +3 -3
- package/src/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_DistinctCount.ts +1 -1
- package/src/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_JoinString.ts +1 -1
- package/src/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Max.ts +5 -5
- package/src/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Min.ts +5 -5
- package/src/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_StdDev_Population.ts +3 -3
- package/src/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_StdDev_Sample.ts +3 -3
- package/src/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperator_Sum.ts +3 -3
- package/src/stores/fetch-structure/projection/post-filter/QueryBuilderPostFilterStateBuilder.ts +2 -2
- package/src/stores/fetch-structure/projection/post-filter/QueryBuilderPostFilterValueSpecificationBuilder.ts +12 -10
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperatorHelper.ts +2 -86
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperatorValueSpecificationBuilder.ts +104 -0
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_Contain.ts +3 -3
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_EndWith.ts +3 -3
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_Equal.ts +8 -7
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThan.ts +4 -4
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThanEqual.ts +3 -3
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_In.ts +2 -2
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_IsEmpty.ts +1 -1
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_LessThan.ts +4 -4
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_LessThanEqual.ts +3 -3
- package/src/stores/fetch-structure/projection/post-filter/operators/QueryBuilderPostFilterOperator_StartWith.ts +3 -3
- package/src/stores/filter/operators/{QueryBuilderFilterOperatorHelper.ts → QueryBuilderFilterOperatorValueSpecificationBuilder.ts} +10 -11
- package/src/stores/filter/operators/QueryBuilderFilterOperator_Contain.ts +5 -5
- package/src/stores/filter/operators/QueryBuilderFilterOperator_EndWith.ts +5 -5
- package/src/stores/filter/operators/QueryBuilderFilterOperator_Equal.ts +11 -10
- package/src/stores/filter/operators/QueryBuilderFilterOperator_GreaterThan.ts +7 -7
- package/src/stores/filter/operators/QueryBuilderFilterOperator_GreaterThanEqual.ts +7 -7
- package/src/stores/filter/operators/QueryBuilderFilterOperator_In.ts +5 -5
- package/src/stores/filter/operators/QueryBuilderFilterOperator_IsEmpty.ts +3 -3
- package/src/stores/filter/operators/QueryBuilderFilterOperator_LessThan.ts +7 -7
- package/src/stores/filter/operators/QueryBuilderFilterOperator_LessThanEqual.ts +7 -7
- package/src/stores/filter/operators/QueryBuilderFilterOperator_StartWith.ts +5 -5
- package/src/stores/shared/LambdaEditorState.ts +118 -0
- package/src/stores/shared/LambdaParameterState.ts +259 -0
- package/src/stores/shared/ValueSpecificationEditorHelper.ts +143 -0
- package/src/stores/shared/ValueSpecificationModifierHelper.ts +177 -0
- package/tsconfig.json +14 -7
- package/lib/graphManager/protocol/pure/v1/V1_QueryBuilder_FunctionExpressionBuilder.d.ts.map +0 -1
- package/lib/graphManager/protocol/pure/v1/V1_QueryBuilder_FunctionExpressionBuilder.js.map +0 -1
- package/lib/graphManager/protocol/pure/v1/V1_QueryBuilder_PropertyExpressionTypeInferenceBuilder.d.ts.map +0 -1
- package/lib/graphManager/protocol/pure/v1/V1_QueryBuilder_PropertyExpressionTypeInferenceBuilder.js.map +0 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchValueSpecificationBuilder.d.ts.map +0 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchValueSpecificationBuilder.js.map +0 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperatorHelper.d.ts.map +0 -1
- package/lib/stores/fetch-structure/projection/aggregation/operators/QueryBuilderAggregateOperatorHelper.js.map +0 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperatorHelper.d.ts.map +0 -1
- package/lib/stores/filter/operators/QueryBuilderFilterOperatorHelper.js.map +0 -1
@@ -14,10 +14,6 @@
|
|
14
14
|
* limitations under the License.
|
15
15
|
*/
|
16
16
|
|
17
|
-
import {
|
18
|
-
functionExpression_setParametersValues,
|
19
|
-
propertyExpression_setParametersValue,
|
20
|
-
} from '@finos/legend-application';
|
21
17
|
import {
|
22
18
|
AbstractPropertyExpression,
|
23
19
|
Class,
|
@@ -78,14 +74,14 @@ const isDefaultDatePropagationSupported = (
|
|
78
74
|
queryBuilderState: QueryBuilderState,
|
79
75
|
prevPropertyExpression?: AbstractPropertyExpression | undefined,
|
80
76
|
): boolean => {
|
81
|
-
const property = currentPropertyExpression.func;
|
77
|
+
const property = currentPropertyExpression.func.value;
|
82
78
|
const graph = queryBuilderState.graphManagerState.graph;
|
83
79
|
// Default date propagation is not supported for current expression when the previous property expression is a derived property.
|
84
80
|
if (
|
85
81
|
prevPropertyExpression &&
|
86
|
-
prevPropertyExpression.func instanceof DerivedProperty &&
|
87
|
-
prevPropertyExpression.func._OWNER.derivedProperties.includes(
|
88
|
-
prevPropertyExpression.func,
|
82
|
+
prevPropertyExpression.func.value instanceof DerivedProperty &&
|
83
|
+
prevPropertyExpression.func.value._OWNER.derivedProperties.includes(
|
84
|
+
prevPropertyExpression.func.value,
|
89
85
|
)
|
90
86
|
) {
|
91
87
|
return false;
|
@@ -94,10 +90,10 @@ const isDefaultDatePropagationSupported = (
|
|
94
90
|
// the previous property expression doesn't match with the global milestonedParameterValues
|
95
91
|
if (
|
96
92
|
prevPropertyExpression &&
|
97
|
-
prevPropertyExpression.func.genericType.value.rawType instanceof Class
|
93
|
+
prevPropertyExpression.func.value.genericType.value.rawType instanceof Class
|
98
94
|
) {
|
99
95
|
const milestoningStereotype = getMilestoneTemporalStereotype(
|
100
|
-
prevPropertyExpression.func.genericType.value.rawType,
|
96
|
+
prevPropertyExpression.func.value.genericType.value.rawType,
|
101
97
|
graph,
|
102
98
|
);
|
103
99
|
if (
|
@@ -152,7 +148,9 @@ export const buildPropertyExpressionChain = (
|
|
152
148
|
graph.getTypicalMultiplicity(TYPICAL_MULTIPLICITY_TYPE.ONE),
|
153
149
|
);
|
154
150
|
newPropertyExpression.func = propertyExpression.func;
|
155
|
-
newPropertyExpression.parametersValues =
|
151
|
+
newPropertyExpression.parametersValues = [
|
152
|
+
...propertyExpression.parametersValues,
|
153
|
+
];
|
156
154
|
|
157
155
|
let nextExpression: ValueSpecification | undefined;
|
158
156
|
let currentExpression: ValueSpecification | undefined = newPropertyExpression;
|
@@ -166,11 +164,15 @@ export const buildPropertyExpressionChain = (
|
|
166
164
|
graph.getTypicalMultiplicity(TYPICAL_MULTIPLICITY_TYPE.ONE),
|
167
165
|
);
|
168
166
|
parameterValue.func = nextExpression.func;
|
169
|
-
parameterValue.parametersValues = nextExpression.parametersValues;
|
167
|
+
parameterValue.parametersValues = [...nextExpression.parametersValues];
|
170
168
|
nextExpression = parameterValue;
|
171
169
|
currentExpression.parametersValues[0] = parameterValue;
|
172
170
|
}
|
173
|
-
if (
|
171
|
+
if (
|
172
|
+
currentExpression instanceof AbstractPropertyExpression &&
|
173
|
+
currentExpression.func.value instanceof DerivedProperty
|
174
|
+
) {
|
175
|
+
const currentPropertyExpression = currentExpression;
|
174
176
|
const parameterValues = currentExpression.parametersValues.slice(1);
|
175
177
|
parameterValues.forEach((parameterValue, index) => {
|
176
178
|
if (parameterValue instanceof INTERNAL__PropagatedValue) {
|
@@ -178,7 +180,7 @@ export const buildPropertyExpressionChain = (
|
|
178
180
|
if (
|
179
181
|
!TEMPORARY__disableDatePropagation &&
|
180
182
|
isDefaultDatePropagationSupported(
|
181
|
-
|
183
|
+
currentPropertyExpression,
|
182
184
|
queryBuilderState,
|
183
185
|
nextExpression instanceof AbstractPropertyExpression
|
184
186
|
? nextExpression
|
@@ -189,41 +191,27 @@ export const buildPropertyExpressionChain = (
|
|
189
191
|
// `INTERNAL_PropagatedValue` then pass the parameters as user explicitly changed values of either of the parameters.
|
190
192
|
if (
|
191
193
|
(index === 1 &&
|
192
|
-
|
193
|
-
.parametersValues.length === 3) ||
|
194
|
+
currentPropertyExpression.parametersValues.length === 3) ||
|
194
195
|
(index === 0 &&
|
195
|
-
|
196
|
-
.parametersValues.length === 3 &&
|
196
|
+
currentPropertyExpression.parametersValues.length === 3 &&
|
197
197
|
!(
|
198
|
-
|
199
|
-
|
198
|
+
currentPropertyExpression.parametersValues[2] instanceof
|
199
|
+
INTERNAL__PropagatedValue
|
200
200
|
))
|
201
201
|
) {
|
202
|
-
|
203
|
-
|
204
|
-
index + 1,
|
205
|
-
parameterValue.getValue(),
|
206
|
-
queryBuilderState.observableContext,
|
207
|
-
);
|
202
|
+
currentPropertyExpression.parametersValues[index + 1] =
|
203
|
+
parameterValue.getValue();
|
208
204
|
} else {
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
),
|
216
|
-
],
|
217
|
-
queryBuilderState.observableContext,
|
218
|
-
);
|
205
|
+
currentPropertyExpression.parametersValues = [
|
206
|
+
guaranteeNonNullable(
|
207
|
+
guaranteeType(currentExpression, AbstractPropertyExpression)
|
208
|
+
.parametersValues[0],
|
209
|
+
),
|
210
|
+
];
|
219
211
|
}
|
220
212
|
} else {
|
221
|
-
|
222
|
-
|
223
|
-
index + 1,
|
224
|
-
parameterValue.getValue(),
|
225
|
-
queryBuilderState.observableContext,
|
226
|
-
);
|
213
|
+
currentPropertyExpression.parametersValues[index + 1] =
|
214
|
+
parameterValue.getValue();
|
227
215
|
}
|
228
216
|
}
|
229
217
|
});
|
@@ -40,6 +40,7 @@ import {
|
|
40
40
|
getMilestoneTemporalStereotype,
|
41
41
|
DerivedProperty,
|
42
42
|
MILESTONING_STEREOTYPE,
|
43
|
+
PackageableElementExplicitReference,
|
43
44
|
} from '@finos/legend-graph';
|
44
45
|
import {
|
45
46
|
addUniqueEntry,
|
@@ -135,8 +136,8 @@ export const unwrapNotExpression = (
|
|
135
136
|
};
|
136
137
|
|
137
138
|
export const buildNotExpression = (
|
138
|
-
graph: PureModel,
|
139
139
|
expression: ValueSpecification,
|
140
|
+
graph: PureModel,
|
140
141
|
): ValueSpecification => {
|
141
142
|
const multiplicityOne = graph.getTypicalMultiplicity(
|
142
143
|
TYPICAL_MULTIPLICITY_TYPE.ONE,
|
@@ -158,7 +159,7 @@ export const isPropertyExpressionChainOptional = (
|
|
158
159
|
propertyExpression &&
|
159
160
|
propertyExpression instanceof AbstractPropertyExpression
|
160
161
|
) {
|
161
|
-
if (propertyExpression.func.multiplicity.lowerBound === 0) {
|
162
|
+
if (propertyExpression.func.value.multiplicity.lowerBound === 0) {
|
162
163
|
isOptional = true;
|
163
164
|
break;
|
164
165
|
}
|
@@ -241,7 +242,10 @@ export const buildGenericLambdaFunctionInstanceValue = (
|
|
241
242
|
const functionInstanceValue = new LambdaFunctionInstanceValue(
|
242
243
|
multiplicityOne,
|
243
244
|
);
|
244
|
-
const functionType = new FunctionType(
|
245
|
+
const functionType = new FunctionType(
|
246
|
+
PackageableElementExplicitReference.create(typeAny),
|
247
|
+
multiplicityOne,
|
248
|
+
);
|
245
249
|
functionType.parameters.push(
|
246
250
|
new VariableExpression(lambdaParameterName, multiplicityOne),
|
247
251
|
);
|
@@ -289,17 +293,18 @@ export const validatePropertyExpressionChain = (
|
|
289
293
|
graph: PureModel,
|
290
294
|
): void => {
|
291
295
|
if (
|
292
|
-
propertyExpression.func.genericType.value.rawType instanceof Class &&
|
293
|
-
propertyExpression.func._OWNER._generatedMilestonedProperties
|
296
|
+
propertyExpression.func.value.genericType.value.rawType instanceof Class &&
|
297
|
+
propertyExpression.func.value._OWNER._generatedMilestonedProperties
|
298
|
+
.length !== 0
|
294
299
|
) {
|
295
|
-
const name = propertyExpression.func.name;
|
300
|
+
const name = propertyExpression.func.value.name;
|
296
301
|
const func =
|
297
|
-
propertyExpression.func._OWNER._generatedMilestonedProperties.find(
|
302
|
+
propertyExpression.func.value._OWNER._generatedMilestonedProperties.find(
|
298
303
|
(e) => e.name === name,
|
299
304
|
);
|
300
305
|
if (func) {
|
301
306
|
const targetStereotype = getMilestoneTemporalStereotype(
|
302
|
-
propertyExpression.func.genericType.value.rawType,
|
307
|
+
propertyExpression.func.value.genericType.value.rawType,
|
303
308
|
graph,
|
304
309
|
);
|
305
310
|
|
@@ -57,6 +57,7 @@ import {
|
|
57
57
|
TdsExecutionResult,
|
58
58
|
type ExecutionResult,
|
59
59
|
getAllSubclasses,
|
60
|
+
PropertyExplicitReference,
|
60
61
|
} from '@finos/legend-graph';
|
61
62
|
import type { QueryBuilderState } from '../QueryBuilderState.js';
|
62
63
|
import { action, flow, flowResult, makeObservable, observable } from 'mobx';
|
@@ -68,6 +69,7 @@ import {
|
|
68
69
|
} from '../QueryBuilderPreviewDataHelper.js';
|
69
70
|
import { QueryBuilderPropertySearchState } from './QueryBuilderPropertySearchState.js';
|
70
71
|
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../graphManager/QueryBuilderSupportedFunctions.js';
|
72
|
+
import { propertyExpression_setFunc } from '../shared/ValueSpecificationModifierHelper.js';
|
71
73
|
|
72
74
|
export enum QUERY_BUILDER_EXPLORER_TREE_DND_TYPE {
|
73
75
|
ROOT = 'ROOT',
|
@@ -209,7 +211,10 @@ export const buildPropertyExpressionFromExplorerTreeNodeData = (
|
|
209
211
|
'',
|
210
212
|
multiplicityOne,
|
211
213
|
);
|
212
|
-
|
214
|
+
propertyExpression_setFunc(
|
215
|
+
propertyExpression,
|
216
|
+
PropertyExplicitReference.create(guaranteeNonNullable(node.property)),
|
217
|
+
);
|
213
218
|
let currentExpression: AbstractPropertyExpression | SimpleFunctionExpression =
|
214
219
|
propertyExpression;
|
215
220
|
let parentNode =
|
@@ -241,7 +246,12 @@ export const buildPropertyExpressionFromExplorerTreeNodeData = (
|
|
241
246
|
'',
|
242
247
|
multiplicityOne,
|
243
248
|
);
|
244
|
-
|
249
|
+
propertyExpression_setFunc(
|
250
|
+
parentPropertyExpression,
|
251
|
+
PropertyExplicitReference.create(
|
252
|
+
guaranteeNonNullable(parentNode.property),
|
253
|
+
),
|
254
|
+
);
|
245
255
|
}
|
246
256
|
currentExpression.parametersValues.push(parentPropertyExpression);
|
247
257
|
if (
|
@@ -44,7 +44,7 @@ import {
|
|
44
44
|
ActionAlertType,
|
45
45
|
} from '@finos/legend-application';
|
46
46
|
import type { LambdaFunctionBuilderOption } from '../../QueryBuilderValueSpecificationBuilderHelper.js';
|
47
|
-
import { appendGraphFetch } from './
|
47
|
+
import { appendGraphFetch } from './QueryBuilderGraphFetchTreeValueSpecificationBuilder.js';
|
48
48
|
import {
|
49
49
|
guaranteeNonNullable,
|
50
50
|
hashArray,
|
@@ -39,12 +39,12 @@ import {
|
|
39
39
|
QueryBuilderExplorerTreeSubTypeNodeData,
|
40
40
|
} from '../../explorer/QueryBuilderExplorerState.js';
|
41
41
|
import type { QueryBuilderState } from '../../QueryBuilderState.js';
|
42
|
+
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../graphManager/QueryBuilderHashUtils.js';
|
43
|
+
import { computed, makeObservable } from 'mobx';
|
42
44
|
import {
|
43
45
|
graphFetchTree_addSubTree,
|
44
46
|
graphFetchTree_removeSubTree,
|
45
|
-
} from '
|
46
|
-
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../graphManager/QueryBuilderHashUtils.js';
|
47
|
-
import { computed, makeObservable } from 'mobx';
|
47
|
+
} from '../../shared/ValueSpecificationModifierHelper.js';
|
48
48
|
|
49
49
|
export class QueryBuilderGraphFetchTreeNodeData
|
50
50
|
implements TreeNodeData, Hashable
|
@@ -137,7 +137,6 @@ export const appendGraphFetch = (
|
|
137
137
|
),
|
138
138
|
multiplicityOne,
|
139
139
|
);
|
140
|
-
|
141
140
|
graphFetchFunc.parametersValues = [precedingExpression, graphFetchInstance];
|
142
141
|
serializeFunction.parametersValues = [graphFetchFunc, graphFetchInstance];
|
143
142
|
lambdaFunction.expressionSequence[0] = serializeFunction;
|
@@ -54,9 +54,9 @@ import {
|
|
54
54
|
DEFAULT_LAMBDA_VARIABLE_NAME,
|
55
55
|
QUERY_BUILDER_SOURCE_ID_LABEL,
|
56
56
|
} from '../../QueryBuilderConfig.js';
|
57
|
-
import { LambdaEditorState } from '@finos/legend-application';
|
58
57
|
import type { QueryBuilderProjectionState } from './QueryBuilderProjectionState.js';
|
59
58
|
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../graphManager/QueryBuilderHashUtils.js';
|
59
|
+
import { LambdaEditorState } from '../../shared/LambdaEditorState.js';
|
60
60
|
|
61
61
|
export const QUERY_BUILDER_PROJECTION_COLUMN_DND_TYPE = 'PROJECTION_COLUMN';
|
62
62
|
|
@@ -147,8 +147,8 @@ export class QueryBuilderSimpleProjectionColumnState
|
|
147
147
|
}
|
148
148
|
|
149
149
|
override getReturnType(): Type | undefined {
|
150
|
-
return this.propertyExpressionState.propertyExpression.func.
|
151
|
-
.value.rawType;
|
150
|
+
return this.propertyExpressionState.propertyExpression.func.value
|
151
|
+
.genericType.value.rawType;
|
152
152
|
}
|
153
153
|
|
154
154
|
get hashCode(): string {
|
@@ -159,7 +159,7 @@ export class QueryBuilderProjectionState
|
|
159
159
|
let currentExpression: ValueSpecification =
|
160
160
|
column.propertyExpressionState.propertyExpression;
|
161
161
|
while (currentExpression instanceof AbstractPropertyExpression) {
|
162
|
-
chunks.push(currentExpression.func.name);
|
162
|
+
chunks.push(currentExpression.func.value.name);
|
163
163
|
currentExpression = guaranteeNonNullable(
|
164
164
|
currentExpression.parametersValues[0],
|
165
165
|
);
|
@@ -157,13 +157,13 @@ export const processTDSProjectionColumnPropertyExpression = (
|
|
157
157
|
);
|
158
158
|
// here we just do a simple check to ensure that if we encounter derived properties
|
159
159
|
// the number of parameters and arguments provided match
|
160
|
-
if (propertyExpression.func instanceof DerivedProperty) {
|
160
|
+
if (propertyExpression.func.value instanceof DerivedProperty) {
|
161
161
|
assertTrue(
|
162
|
-
(Array.isArray(propertyExpression.func.parameters)
|
163
|
-
? propertyExpression.func.parameters.length
|
162
|
+
(Array.isArray(propertyExpression.func.value.parameters)
|
163
|
+
? propertyExpression.func.value.parameters.length
|
164
164
|
: 0) ===
|
165
165
|
propertyExpression.parametersValues.length - 1,
|
166
|
-
`Can't process property expression: derived property '${propertyExpression.func.name}' expects number of provided arguments to match number of parameters`,
|
166
|
+
`Can't process property expression: derived property '${propertyExpression.func.value.name}' expects number of provided arguments to match number of parameters`,
|
167
167
|
);
|
168
168
|
}
|
169
169
|
// Take care of chains of subtype (a pattern that is not useful, but we want to support and rectify)
|
package/src/stores/fetch-structure/projection/QueryBuilderProjectionValueSpecificationBuilder.ts
CHANGED
@@ -82,7 +82,7 @@ const buildSortExpression = (
|
|
82
82
|
|
83
83
|
const appendResultSetModifier = (
|
84
84
|
resultModifierState: QueryResultSetModifierState,
|
85
|
-
|
85
|
+
lambdaFunction: LambdaFunction,
|
86
86
|
options?:
|
87
87
|
| {
|
88
88
|
overridingLimit?: number | undefined;
|
@@ -93,8 +93,8 @@ const appendResultSetModifier = (
|
|
93
93
|
resultModifierState.projectionState.queryBuilderState.graphManagerState.graph.getTypicalMultiplicity(
|
94
94
|
TYPICAL_MULTIPLICITY_TYPE.ONE,
|
95
95
|
);
|
96
|
-
if (
|
97
|
-
const func =
|
96
|
+
if (lambdaFunction.expressionSequence.length === 1) {
|
97
|
+
const func = lambdaFunction.expressionSequence[0];
|
98
98
|
if (func instanceof SimpleFunctionExpression) {
|
99
99
|
if (
|
100
100
|
matchFunctionName(func.functionName, [
|
@@ -165,18 +165,16 @@ const appendResultSetModifier = (
|
|
165
165
|
),
|
166
166
|
multiplicityOne,
|
167
167
|
);
|
168
|
-
|
169
168
|
takeFunction.parametersValues[0] = currentExpression;
|
170
169
|
takeFunction.parametersValues[1] = limit;
|
171
170
|
currentExpression = takeFunction;
|
172
171
|
}
|
173
|
-
|
174
|
-
|
175
|
-
return lambda;
|
172
|
+
lambdaFunction.expressionSequence[0] = currentExpression;
|
173
|
+
return lambdaFunction;
|
176
174
|
}
|
177
175
|
}
|
178
176
|
}
|
179
|
-
return
|
177
|
+
return lambdaFunction;
|
180
178
|
};
|
181
179
|
|
182
180
|
export const appendProjection = (
|
@@ -310,7 +308,6 @@ export const appendProjection = (
|
|
310
308
|
columnLambda,
|
311
309
|
aggregateLambda,
|
312
310
|
];
|
313
|
-
|
314
311
|
aggregateLambdas.values.push(aggregateFunctionExpression);
|
315
312
|
} else {
|
316
313
|
colLambdas.values.push(columnLambda);
|
@@ -30,8 +30,8 @@ import type { QueryBuilderAggregateOperator } from '../QueryBuilderAggregateOper
|
|
30
30
|
|
31
31
|
export const buildAggregateExpression = (
|
32
32
|
operatorFunctionFullPath: string,
|
33
|
-
graph: PureModel,
|
34
33
|
variableName: string,
|
34
|
+
graph: PureModel,
|
35
35
|
): ValueSpecification => {
|
36
36
|
const multiplicityOne = graph.getTypicalMultiplicity(
|
37
37
|
TYPICAL_MULTIPLICITY_TYPE.ONE,
|
@@ -32,7 +32,7 @@ import {
|
|
32
32
|
import {
|
33
33
|
buildAggregateColumnState,
|
34
34
|
buildAggregateExpression,
|
35
|
-
} from './
|
35
|
+
} from './QueryBuilderAggregateOperatorValueSpecificationBuilder.js';
|
36
36
|
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
37
37
|
import { type Hashable, hashArray } from '@finos/legend-shared';
|
38
38
|
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../../../graphManager/QueryBuilderHashUtils.js';
|
@@ -53,7 +53,7 @@ export class QueryBuilderAggregateOperator_Average
|
|
53
53
|
) {
|
54
54
|
const propertyType =
|
55
55
|
projectionColumnState.propertyExpressionState.propertyExpression.func
|
56
|
-
.genericType.value.rawType;
|
56
|
+
.value.genericType.value.rawType;
|
57
57
|
return (
|
58
58
|
[
|
59
59
|
PRIMITIVE_TYPE.NUMBER,
|
@@ -73,8 +73,8 @@ export class QueryBuilderAggregateOperator_Average
|
|
73
73
|
): ValueSpecification {
|
74
74
|
return buildAggregateExpression(
|
75
75
|
QUERY_BUILDER_SUPPORTED_FUNCTIONS.AVERAGE,
|
76
|
-
graph,
|
77
76
|
variableName,
|
77
|
+
graph,
|
78
78
|
);
|
79
79
|
}
|
80
80
|
|
@@ -33,7 +33,7 @@ import {
|
|
33
33
|
import {
|
34
34
|
buildAggregateColumnState,
|
35
35
|
buildAggregateExpression,
|
36
|
-
} from './
|
36
|
+
} from './QueryBuilderAggregateOperatorValueSpecificationBuilder.js';
|
37
37
|
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
38
38
|
import { type Hashable, hashArray } from '@finos/legend-shared';
|
39
39
|
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../../../graphManager/QueryBuilderHashUtils.js';
|
@@ -54,7 +54,7 @@ export class QueryBuilderAggregateOperator_Count
|
|
54
54
|
) {
|
55
55
|
const propertyType =
|
56
56
|
projectionColumnState.propertyExpressionState.propertyExpression.func
|
57
|
-
.genericType.value.rawType;
|
57
|
+
.value.genericType.value.rawType;
|
58
58
|
return (
|
59
59
|
(
|
60
60
|
[
|
@@ -81,8 +81,8 @@ export class QueryBuilderAggregateOperator_Count
|
|
81
81
|
): ValueSpecification {
|
82
82
|
return buildAggregateExpression(
|
83
83
|
QUERY_BUILDER_SUPPORTED_FUNCTIONS.COUNT,
|
84
|
-
graph,
|
85
84
|
variableName,
|
85
|
+
graph,
|
86
86
|
);
|
87
87
|
}
|
88
88
|
|
@@ -32,7 +32,7 @@ import {
|
|
32
32
|
import {
|
33
33
|
buildAggregateColumnState,
|
34
34
|
buildAggregateExpression,
|
35
|
-
} from './
|
35
|
+
} from './QueryBuilderAggregateOperatorValueSpecificationBuilder.js';
|
36
36
|
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
37
37
|
import { type Hashable, hashArray } from '@finos/legend-shared';
|
38
38
|
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../../../graphManager/QueryBuilderHashUtils.js';
|
@@ -53,7 +53,7 @@ export class QueryBuilderAggregateOperator_Distinct
|
|
53
53
|
) {
|
54
54
|
const propertyType =
|
55
55
|
projectionColumnState.propertyExpressionState.propertyExpression.func
|
56
|
-
.genericType.value.rawType;
|
56
|
+
.value.genericType.value.rawType;
|
57
57
|
return (
|
58
58
|
(
|
59
59
|
[
|
@@ -80,8 +80,8 @@ export class QueryBuilderAggregateOperator_Distinct
|
|
80
80
|
): ValueSpecification {
|
81
81
|
return buildAggregateExpression(
|
82
82
|
QUERY_BUILDER_SUPPORTED_FUNCTIONS.UNIQUE_VALUE_ONLY,
|
83
|
-
graph,
|
84
83
|
variableName,
|
84
|
+
graph,
|
85
85
|
);
|
86
86
|
}
|
87
87
|
|
@@ -60,7 +60,7 @@ export class QueryBuilderAggregateOperator_JoinString
|
|
60
60
|
) {
|
61
61
|
const propertyType =
|
62
62
|
projectionColumnState.propertyExpressionState.propertyExpression.func
|
63
|
-
.genericType.value.rawType;
|
63
|
+
.value.genericType.value.rawType;
|
64
64
|
// NOTE: Engine does not support Enumerations at the moment.
|
65
65
|
return PRIMITIVE_TYPE.STRING === propertyType.path;
|
66
66
|
}
|
@@ -32,7 +32,7 @@ import {
|
|
32
32
|
import {
|
33
33
|
buildAggregateColumnState,
|
34
34
|
buildAggregateExpression,
|
35
|
-
} from './
|
35
|
+
} from './QueryBuilderAggregateOperatorValueSpecificationBuilder.js';
|
36
36
|
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
37
37
|
import { type Hashable, hashArray } from '@finos/legend-shared';
|
38
38
|
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../../../graphManager/QueryBuilderHashUtils.js';
|
@@ -53,7 +53,7 @@ export class QueryBuilderAggregateOperator_Max
|
|
53
53
|
) {
|
54
54
|
const propertyType =
|
55
55
|
projectionColumnState.propertyExpressionState.propertyExpression.func
|
56
|
-
.genericType.value.rawType;
|
56
|
+
.value.genericType.value.rawType;
|
57
57
|
return (
|
58
58
|
[
|
59
59
|
PRIMITIVE_TYPE.NUMBER,
|
@@ -82,13 +82,13 @@ export class QueryBuilderAggregateOperator_Max
|
|
82
82
|
PRIMITIVE_TYPE.DATETIME,
|
83
83
|
] as string[]
|
84
84
|
).includes(
|
85
|
-
propertyExpression?.func.genericType.value.rawType.path ??
|
85
|
+
propertyExpression?.func.value.genericType.value.rawType.path ??
|
86
86
|
PRIMITIVE_TYPE.NUMBER, // this decision does not affect the output expression
|
87
87
|
)
|
88
88
|
? QUERY_BUILDER_SUPPORTED_FUNCTIONS.DATE_MAX
|
89
89
|
: QUERY_BUILDER_SUPPORTED_FUNCTIONS.MAX,
|
90
|
-
graph,
|
91
90
|
variableName,
|
91
|
+
graph,
|
92
92
|
);
|
93
93
|
}
|
94
94
|
|
@@ -102,7 +102,7 @@ export class QueryBuilderAggregateOperator_Max
|
|
102
102
|
) {
|
103
103
|
const propertyType =
|
104
104
|
projectionColumnState.propertyExpressionState.propertyExpression.func
|
105
|
-
.genericType.value.rawType;
|
105
|
+
.value.genericType.value.rawType;
|
106
106
|
switch (propertyType.path) {
|
107
107
|
case PRIMITIVE_TYPE.NUMBER:
|
108
108
|
case PRIMITIVE_TYPE.INTEGER:
|
@@ -32,7 +32,7 @@ import {
|
|
32
32
|
import {
|
33
33
|
buildAggregateColumnState,
|
34
34
|
buildAggregateExpression,
|
35
|
-
} from './
|
35
|
+
} from './QueryBuilderAggregateOperatorValueSpecificationBuilder.js';
|
36
36
|
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
37
37
|
import { type Hashable, hashArray } from '@finos/legend-shared';
|
38
38
|
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../../../graphManager/QueryBuilderHashUtils.js';
|
@@ -53,7 +53,7 @@ export class QueryBuilderAggregateOperator_Min
|
|
53
53
|
) {
|
54
54
|
const propertyType =
|
55
55
|
projectionColumnState.propertyExpressionState.propertyExpression.func
|
56
|
-
.genericType.value.rawType;
|
56
|
+
.value.genericType.value.rawType;
|
57
57
|
return (
|
58
58
|
[
|
59
59
|
PRIMITIVE_TYPE.NUMBER,
|
@@ -82,13 +82,13 @@ export class QueryBuilderAggregateOperator_Min
|
|
82
82
|
PRIMITIVE_TYPE.DATETIME,
|
83
83
|
] as string[]
|
84
84
|
).includes(
|
85
|
-
propertyExpression?.func.genericType.value.rawType.path ??
|
85
|
+
propertyExpression?.func.value.genericType.value.rawType.path ??
|
86
86
|
PRIMITIVE_TYPE.NUMBER, // this decision does not affect the output expression
|
87
87
|
)
|
88
88
|
? QUERY_BUILDER_SUPPORTED_FUNCTIONS.DATE_MIN
|
89
89
|
: QUERY_BUILDER_SUPPORTED_FUNCTIONS.MIN,
|
90
|
-
graph,
|
91
90
|
variableName,
|
91
|
+
graph,
|
92
92
|
);
|
93
93
|
}
|
94
94
|
|
@@ -102,7 +102,7 @@ export class QueryBuilderAggregateOperator_Min
|
|
102
102
|
) {
|
103
103
|
const propertyType =
|
104
104
|
projectionColumnState.propertyExpressionState.propertyExpression.func
|
105
|
-
.genericType.value.rawType;
|
105
|
+
.value.genericType.value.rawType;
|
106
106
|
switch (propertyType.path) {
|
107
107
|
case PRIMITIVE_TYPE.NUMBER:
|
108
108
|
case PRIMITIVE_TYPE.INTEGER:
|
@@ -32,7 +32,7 @@ import {
|
|
32
32
|
import {
|
33
33
|
buildAggregateColumnState,
|
34
34
|
buildAggregateExpression,
|
35
|
-
} from './
|
35
|
+
} from './QueryBuilderAggregateOperatorValueSpecificationBuilder.js';
|
36
36
|
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
37
37
|
import { type Hashable, hashArray } from '@finos/legend-shared';
|
38
38
|
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../../../graphManager/QueryBuilderHashUtils.js';
|
@@ -53,7 +53,7 @@ export class QueryBuilderAggregateOperator_StdDev_Population
|
|
53
53
|
) {
|
54
54
|
const propertyType =
|
55
55
|
projectionColumnState.propertyExpressionState.propertyExpression.func
|
56
|
-
.genericType.value.rawType;
|
56
|
+
.value.genericType.value.rawType;
|
57
57
|
return (
|
58
58
|
[
|
59
59
|
PRIMITIVE_TYPE.NUMBER,
|
@@ -73,8 +73,8 @@ export class QueryBuilderAggregateOperator_StdDev_Population
|
|
73
73
|
): ValueSpecification {
|
74
74
|
return buildAggregateExpression(
|
75
75
|
QUERY_BUILDER_SUPPORTED_FUNCTIONS.STD_DEV_POPULATION,
|
76
|
-
graph,
|
77
76
|
variableName,
|
77
|
+
graph,
|
78
78
|
);
|
79
79
|
}
|
80
80
|
|
@@ -32,7 +32,7 @@ import {
|
|
32
32
|
import {
|
33
33
|
buildAggregateColumnState,
|
34
34
|
buildAggregateExpression,
|
35
|
-
} from './
|
35
|
+
} from './QueryBuilderAggregateOperatorValueSpecificationBuilder.js';
|
36
36
|
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
37
37
|
import { type Hashable, hashArray } from '@finos/legend-shared';
|
38
38
|
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../../../graphManager/QueryBuilderHashUtils.js';
|
@@ -53,7 +53,7 @@ export class QueryBuilderAggregateOperator_StdDev_Sample
|
|
53
53
|
) {
|
54
54
|
const propertyType =
|
55
55
|
projectionColumnState.propertyExpressionState.propertyExpression.func
|
56
|
-
.genericType.value.rawType;
|
56
|
+
.value.genericType.value.rawType;
|
57
57
|
return (
|
58
58
|
[
|
59
59
|
PRIMITIVE_TYPE.NUMBER,
|
@@ -73,8 +73,8 @@ export class QueryBuilderAggregateOperator_StdDev_Sample
|
|
73
73
|
): ValueSpecification {
|
74
74
|
return buildAggregateExpression(
|
75
75
|
QUERY_BUILDER_SUPPORTED_FUNCTIONS.STD_DEV_SAMPLE,
|
76
|
-
graph,
|
77
76
|
variableName,
|
77
|
+
graph,
|
78
78
|
);
|
79
79
|
}
|
80
80
|
|