@adaptabletools/adaptable 12.1.6 → 12.1.8-canary.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/base.css +11 -49
- package/bundle.cjs.js +106 -106
- package/index.css +13 -60
- package/package.json +1 -1
- package/publishTimestamp.d.ts +1 -1
- package/publishTimestamp.js +1 -1
- package/src/AdaptableInterfaces/IAdaptable.d.ts +2 -0
- package/src/AdaptableOptions/ColumnOptions.d.ts +2 -4
- package/src/AdaptableOptions/FilterOptions.d.ts +12 -0
- package/src/AdaptableOptions/FinancePluginOptions.d.ts +22 -1
- package/src/AdaptableOptions/StateOptions.d.ts +25 -12
- package/src/Api/ColumnApi.d.ts +5 -0
- package/src/Api/ExportApi.d.ts +5 -0
- package/src/Api/FilterApi.d.ts +23 -0
- package/src/Api/FlashingCellApi.d.ts +8 -0
- package/src/Api/GridApi.d.ts +1 -0
- package/src/Api/Implementation/ColumnApiImpl.d.ts +1 -0
- package/src/Api/Implementation/ColumnApiImpl.js +5 -1
- package/src/Api/Implementation/ExportApiImpl.d.ts +3 -1
- package/src/Api/Implementation/ExportApiImpl.js +19 -3
- package/src/Api/Implementation/FilterApiImpl.d.ts +5 -0
- package/src/Api/Implementation/FilterApiImpl.js +35 -3
- package/src/Api/Implementation/FlashingCellApiImpl.d.ts +1 -0
- package/src/Api/Implementation/FlashingCellApiImpl.js +4 -0
- package/src/Api/Implementation/GridApiImpl.d.ts +1 -0
- package/src/Api/Implementation/InternalApiImpl.d.ts +0 -1
- package/src/Api/Implementation/InternalApiImpl.js +0 -3
- package/src/Api/Implementation/PredicateApiImpl.js +4 -0
- package/src/Api/Implementation/QueryLanguageApiImpl.js +9 -1
- package/src/Api/InternalApi.d.ts +0 -1
- package/src/Api/SystemStatusApi.d.ts +1 -1
- package/src/Api/ToolPanelApi.d.ts +1 -1
- package/src/PredefinedConfig/CalculatedColumnState.d.ts +2 -2
- package/src/PredefinedConfig/Common/AdaptablePredicate.js +30 -10
- package/src/PredefinedConfig/Common/AdaptableQuery.js +1 -1
- package/src/PredefinedConfig/Common/AggregationColumns.d.ts +6 -0
- package/src/PredefinedConfig/Common/AggregationColumns.js +4 -0
- package/src/PredefinedConfig/Common/ColumnFilter.d.ts +2 -2
- package/src/PredefinedConfig/Common/Enums.d.ts +0 -15
- package/src/PredefinedConfig/Common/Enums.js +1 -18
- package/src/PredefinedConfig/Common/SpecialColumnSettings.d.ts +6 -6
- package/src/PredefinedConfig/ExportState.d.ts +12 -4
- package/src/PredefinedConfig/LayoutState.d.ts +2 -1
- package/src/PredefinedConfig/PopupState.d.ts +1 -2
- package/src/Redux/ActionsReducers/AlertRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/AlertRedux.js +1 -1
- package/src/Redux/ActionsReducers/ConditionalStyleRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/ConditionalStyleRedux.js +1 -1
- package/src/Redux/ActionsReducers/CustomSortRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/CustomSortRedux.js +1 -1
- package/src/Redux/ActionsReducers/FlashingCellRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/FlashingCellRedux.js +1 -1
- package/src/Redux/ActionsReducers/FormatColumnRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/FormatColumnRedux.js +1 -1
- package/src/Redux/ActionsReducers/LayoutRedux.d.ts +28 -0
- package/src/Redux/ActionsReducers/LayoutRedux.js +80 -2
- package/src/Redux/ActionsReducers/PlusMinusRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/PlusMinusRedux.js +1 -1
- package/src/Redux/ActionsReducers/PopupRedux.d.ts +0 -2
- package/src/Redux/ActionsReducers/PopupRedux.js +1 -28
- package/src/Redux/ActionsReducers/ScheduleRedux.d.ts +5 -5
- package/src/Redux/ActionsReducers/ScheduleRedux.js +5 -5
- package/src/Redux/ActionsReducers/ShortcutRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/ShortcutRedux.js +1 -1
- package/src/Redux/ActionsReducers/SystemRedux.d.ts +1 -2
- package/src/Redux/ActionsReducers/SystemRedux.js +1 -2
- package/src/Redux/Store/AdaptableStore.js +20 -6
- package/src/Strategy/AlertModule.d.ts +1 -0
- package/src/Strategy/AlertModule.js +20 -0
- package/src/Strategy/CalculatedColumnModule.js +2 -2
- package/src/Strategy/ExportModule.d.ts +0 -1
- package/src/Strategy/ExportModule.js +0 -16
- package/src/Strategy/FilterModule.js +6 -0
- package/src/Strategy/FlashingCellModule.js +2 -2
- package/src/Strategy/Interface/IModule.d.ts +4 -0
- package/src/Strategy/LayoutModule.js +20 -20
- package/src/Strategy/Utilities/FormatColumn/getFormatColumnStyleViewItems.js +16 -1
- package/src/Strategy/Utilities/Layout/getLayoutFilterViewItems.js +15 -11
- package/src/Utilities/Constants/DocumentationLinkConstants.d.ts +1 -0
- package/src/Utilities/Constants/DocumentationLinkConstants.js +2 -1
- package/src/Utilities/Defaults/DefaultAdaptableOptions.js +2 -0
- package/src/Utilities/ExpressionFunctions/aggregatedBooleanExpressionFunctions.d.ts +12 -2
- package/src/Utilities/ExpressionFunctions/aggregatedBooleanExpressionFunctions.js +30 -66
- package/src/Utilities/ExpressionFunctions/aggregatedScalarExpressionFunctions.d.ts +22 -6
- package/src/Utilities/ExpressionFunctions/aggregatedScalarExpressionFunctions.js +423 -220
- package/src/Utilities/ExpressionFunctions/expressionFunctionUtils.d.ts +7 -1
- package/src/Utilities/ExpressionFunctions/expressionFunctionUtils.js +23 -7
- package/src/Utilities/ExpressionFunctions/scalarAggregationHelper.d.ts +0 -1
- package/src/Utilities/ExpressionFunctions/scalarAggregationHelper.js +6 -54
- package/src/Utilities/ExpressionFunctions/scalarExpressionFunctions.js +17 -5
- package/src/Utilities/Helpers/CalendarHelper.js +10 -7
- package/src/Utilities/Helpers/DateHelper.d.ts +0 -26
- package/src/Utilities/Helpers/DateHelper.js +2 -32
- package/src/Utilities/Interface/MessagePopups.d.ts +0 -4
- package/src/Utilities/ObjectFactory.d.ts +6 -4
- package/src/Utilities/ObjectFactory.js +30 -17
- package/src/Utilities/Services/AggregatedScalarLiveValue.d.ts +25 -0
- package/src/Utilities/Services/AggregatedScalarLiveValue.js +103 -0
- package/src/Utilities/Services/AlertService.d.ts +0 -1
- package/src/Utilities/Services/AlertService.js +5 -17
- package/src/Utilities/Services/CalculatedColumnExpressionService.d.ts +4 -4
- package/src/Utilities/Services/CalculatedColumnExpressionService.js +29 -154
- package/src/Utilities/Services/Interface/ICalculatedColumnExpressionService.d.ts +2 -2
- package/src/Utilities/Services/Interface/IQueryLanguageService.d.ts +6 -3
- package/src/Utilities/Services/QueryLanguageService.d.ts +6 -3
- package/src/Utilities/Services/QueryLanguageService.js +23 -6
- package/src/Utilities/Services/ReportService.js +47 -46
- package/src/View/AdaptableView.js +1 -2
- package/src/View/CalculatedColumn/Utilities/getCalculatedColumnSettingsTags.d.ts +2 -0
- package/src/View/CalculatedColumn/Utilities/{getCalculatedColumnSettingTags.js → getCalculatedColumnSettingsTags.js} +5 -3
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnDefinitionWizardSection.d.ts +10 -0
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnDefinitionWizardSection.js +80 -0
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnExpressionWizardSection.js +21 -15
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnSettingsWizardSection.d.ts +1 -2
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnSettingsWizardSection.js +10 -53
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnWizard.js +14 -3
- package/src/View/Components/AdaptableDateInput/index.js +1 -1
- package/src/View/Components/AdaptableObjectList/AdaptableObjectCompactList.js +42 -6
- package/src/View/Components/AdaptableObjectList/AdaptableObjectList.js +1 -1
- package/src/View/Components/EntityRulesEditor/index.js +26 -5
- package/src/View/Components/FilterForm/FilterForm.js +8 -4
- package/src/View/Components/FilterForm/ListBoxFilterForm.js +1 -0
- package/src/View/Components/FilterForm/QuickFilterForm.js +10 -6
- package/src/View/Components/PermittedValuesSelector/PermitedValuesSelector.d.ts +9 -0
- package/src/View/Components/PermittedValuesSelector/PermitedValuesSelector.js +28 -0
- package/src/View/Components/PermittedValuesSelector/index.d.ts +1 -0
- package/src/View/Components/PermittedValuesSelector/index.js +5 -0
- package/src/View/Components/Popups/AdaptablePopup/Navigation.js +2 -2
- package/src/View/Components/Popups/AdaptableToaster.js +2 -7
- package/src/View/Components/Popups/WindowPopups/windowFactory.d.ts +0 -1
- package/src/View/Components/Popups/WindowPopups/windowFactory.js +1 -4
- package/src/View/Export/ExportViewPanel.d.ts +1 -2
- package/src/View/Export/ExportViewPanel.js +2 -6
- package/src/View/Export/Wizard/ReportColumnTypeWizard.d.ts +1 -2
- package/src/View/Export/Wizard/ReportColumnTypeWizard.js +11 -12
- package/src/View/Export/Wizard/ReportRowTypeWizard.d.ts +1 -2
- package/src/View/Export/Wizard/ReportRowTypeWizard.js +12 -13
- package/src/View/Export/Wizard/ReportSettingsWizard.js +1 -2
- package/src/View/Filter/FilterViewPanel.js +20 -4
- package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.js +1 -1
- package/src/View/FreeTextColumn/FreeTextColumnSummary.js +1 -2
- package/src/View/FreeTextColumn/Wizard/FreeTextColumnSettingsWizardSection.d.ts +1 -1
- package/src/View/FreeTextColumn/Wizard/FreeTextColumnWizard.js +1 -1
- package/src/View/Layout/Wizard/{LayoutEditor → Components}/ColumnLabels.d.ts +0 -0
- package/src/View/Layout/Wizard/{LayoutEditor → Components}/ColumnLabels.js +0 -0
- package/src/View/Layout/Wizard/LayoutWizard.js +1 -0
- package/src/View/Layout/Wizard/sections/AggregationsSection.d.ts +1 -0
- package/src/View/Layout/Wizard/sections/AggregationsSection.js +69 -8
- package/src/View/Layout/Wizard/sections/ColumnsSection.js +1 -1
- package/src/View/Query/QueryViewPanel.js +1 -1
- package/src/agGrid/Adaptable.d.ts +11 -3
- package/src/agGrid/Adaptable.js +224 -150
- package/src/agGrid/agGridHelper.d.ts +1 -0
- package/src/agGrid/agGridHelper.js +5 -3
- package/src/agGrid/agGridMenuHelper.d.ts +1 -0
- package/src/agGrid/agGridMenuHelper.js +4 -2
- package/src/agGrid/weightedAverage.d.ts +6 -0
- package/src/agGrid/weightedAverage.js +66 -0
- package/src/bundle-dependencies/bundles/react-toastify/index.js +1 -1
- package/src/components/ExpressionEditor/BaseEditorInput.d.ts +1 -0
- package/src/components/ExpressionEditor/BaseEditorInput.js +2 -3
- package/src/components/ExpressionEditor/EditorInput.d.ts +1 -1
- package/src/components/ExpressionEditor/EditorInput.js +24 -4
- package/src/components/ExpressionEditor/{EditorInputReactive.d.ts → EditorInputWithWhereClause.d.ts} +3 -3
- package/src/components/ExpressionEditor/{EditorInputReactive.js → EditorInputWithWhereClause.js} +6 -5
- package/src/components/ExpressionEditor/editorButtonsAggregatedBoolean.d.ts +2 -0
- package/src/components/ExpressionEditor/{editorButtonsReactive.js → editorButtonsAggregatedBoolean.js} +22 -37
- package/src/components/ExpressionEditor/editorButtonsAggregatedScalar.js +5 -10
- package/src/components/ExpressionEditor/editorButtonsCumulativeAggregatedScalar.d.ts +2 -0
- package/src/components/ExpressionEditor/editorButtonsCumulativeAggregatedScalar.js +50 -0
- package/src/components/ExpressionEditor/editorButtonsObservable.d.ts +2 -0
- package/src/components/ExpressionEditor/editorButtonsObservable.js +40 -0
- package/src/components/ExpressionEditor/index.d.ts +1 -1
- package/src/components/ExpressionEditor/index.js +26 -5
- package/src/metamodel/adaptable.metamodel.d.ts +55 -1
- package/src/metamodel/adaptable.metamodel.js +1 -1
- package/src/types.d.ts +3 -3
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/src/View/CalculatedColumn/Utilities/getCalculatedColumnSettingTags.d.ts +0 -2
- package/src/View/Layout/LayoutEditorStandalonePopup.d.ts +0 -3
- package/src/View/Layout/LayoutEditorStandalonePopup.js +0 -78
- package/src/View/Layout/Wizard/LayoutEditor/ColumnList.d.ts +0 -27
- package/src/View/Layout/Wizard/LayoutEditor/ColumnList.js +0 -86
- package/src/View/Layout/Wizard/LayoutEditor/ColumnSortList.d.ts +0 -16
- package/src/View/Layout/Wizard/LayoutEditor/ColumnSortList.js +0 -89
- package/src/View/Layout/Wizard/LayoutEditor/PivotList.d.ts +0 -15
- package/src/View/Layout/Wizard/LayoutEditor/PivotList.js +0 -70
- package/src/View/Layout/Wizard/LayoutEditor/RowGroupsList.d.ts +0 -15
- package/src/View/Layout/Wizard/LayoutEditor/RowGroupsList.js +0 -70
- package/src/View/Layout/Wizard/LayoutEditor/droppableIds.d.ts +0 -7
- package/src/View/Layout/Wizard/LayoutEditor/droppableIds.js +0 -11
- package/src/View/Layout/Wizard/LayoutEditor/getItemStyle.d.ts +0 -6
- package/src/View/Layout/Wizard/LayoutEditor/getItemStyle.js +0 -26
- package/src/View/Layout/Wizard/LayoutEditor/index.d.ts +0 -9
- package/src/View/Layout/Wizard/LayoutEditor/index.js +0 -367
- package/src/View/Layout/Wizard/LayoutEditor/reducer.d.ts +0 -28
- package/src/View/Layout/Wizard/LayoutEditor/reducer.js +0 -46
- package/src/View/Layout/Wizard/LayoutEditor/utils.d.ts +0 -10
- package/src/View/Layout/Wizard/LayoutEditor/utils.js +0 -14
- package/src/View/Layout/Wizard/LayoutEditorWizard.d.ts +0 -30
- package/src/View/Layout/Wizard/LayoutEditorWizard.js +0 -132
- package/src/components/ExpressionEditor/editorButtonsReactive.d.ts +0 -2
package/index.css
CHANGED
|
@@ -2598,66 +2598,6 @@ template {
|
|
|
2598
2598
|
--ab-cmp-toolpanelpanel_body__background: var(--ab-cmp-dashboardpanel_body__background);
|
|
2599
2599
|
--ab-cmp-toolpanelpanel_body__padding: var(--ab-cmp-dashboardpanel_body__padding); }
|
|
2600
2600
|
|
|
2601
|
-
.ab-LayoutEditor {
|
|
2602
|
-
overflow: auto;
|
|
2603
|
-
display: grid;
|
|
2604
|
-
padding: var(--ab-space-2);
|
|
2605
|
-
flex: 1 1 0;
|
|
2606
|
-
min-height: 0;
|
|
2607
|
-
grid-template-columns: 28rem 1fr;
|
|
2608
|
-
grid-template-rows: repeat(3, 1fr);
|
|
2609
|
-
grid-column-gap: 0px;
|
|
2610
|
-
grid-row-gap: 0px;
|
|
2611
|
-
row-gap: var(--ab-space-2);
|
|
2612
|
-
column-gap: var(--ab-space-2);
|
|
2613
|
-
grid-gap: var(--ab-space-2); }
|
|
2614
|
-
|
|
2615
|
-
.ab-LayoutEditor,
|
|
2616
|
-
.ab-LayoutEditor * {
|
|
2617
|
-
box-sizing: border-box; }
|
|
2618
|
-
|
|
2619
|
-
.ab-LayoutEditor__ColumnList {
|
|
2620
|
-
overflow: auto; }
|
|
2621
|
-
|
|
2622
|
-
.ab-LayoutEditor__ColumnListPanel {
|
|
2623
|
-
grid-area: 1 / 1 / 4 / 2; }
|
|
2624
|
-
|
|
2625
|
-
.ab-LayoutEditor__ColumnSortListPanel {
|
|
2626
|
-
grid-area: 1 / 2 / 2 / 3; }
|
|
2627
|
-
|
|
2628
|
-
.ab-LayoutEditor__RowGroupsListPanel {
|
|
2629
|
-
grid-area: 2 / 2 / 3 / 3; }
|
|
2630
|
-
|
|
2631
|
-
.ab-LayoutEditor__PivotListPanel {
|
|
2632
|
-
grid-area: 3 / 2 / 4 / 3; }
|
|
2633
|
-
|
|
2634
|
-
.ab-LayoutEditor__PivotList--empty,
|
|
2635
|
-
.ab-LayoutEditor__RowGroupsList--empty,
|
|
2636
|
-
.ab-LayoutEditor__ColumnSortList--empty {
|
|
2637
|
-
display: flex;
|
|
2638
|
-
flex-flow: column;
|
|
2639
|
-
align-items: center;
|
|
2640
|
-
justify-content: center; }
|
|
2641
|
-
|
|
2642
|
-
.ab-LayoutEditor__PivotList,
|
|
2643
|
-
.ab-LayoutEditor__RowGroupsList,
|
|
2644
|
-
.ab-LayoutEditor__ColumnSortList {
|
|
2645
|
-
padding-top: var(--ab-space-2); }
|
|
2646
|
-
|
|
2647
|
-
.ab-LayoutEditor__PivotList__column,
|
|
2648
|
-
.ab-LayoutEditor__RowGroupsList__column,
|
|
2649
|
-
.ab-LayoutEditor__ColumnSortList__column,
|
|
2650
|
-
.ab-LayoutEditor__ColumnList__column {
|
|
2651
|
-
background: var(--ab-color-primary);
|
|
2652
|
-
color: var(--ab-color-text-on-primary);
|
|
2653
|
-
margin: 0 0 var(--ab-space-2) 0; }
|
|
2654
|
-
|
|
2655
|
-
.ab-LayoutEditor__PivotList__column,
|
|
2656
|
-
.ab-LayoutEditor__RowGroupsList__column,
|
|
2657
|
-
.ab-LayoutEditor__ColumnSortList__column {
|
|
2658
|
-
padding-top: var(--ab-space-2);
|
|
2659
|
-
padding-bottom: var(--ab-space-2); }
|
|
2660
|
-
|
|
2661
2601
|
:root {
|
|
2662
2602
|
--ab-cmp-popover__border-radius: var(--ab__border-radius);
|
|
2663
2603
|
--ab-cmp-popover__background: var(--ab-color-defaultbackground);
|
|
@@ -2798,6 +2738,13 @@ template {
|
|
|
2798
2738
|
--ab-cmp-adaptable-layout-wizard-column-input__max-width: 200px;
|
|
2799
2739
|
--ab-cmp-adaptable-layout-wizard-column-input__width: 100%; }
|
|
2800
2740
|
|
|
2741
|
+
.ab-PermitedValuesSelector__PopupContent {
|
|
2742
|
+
z-index: 1000;
|
|
2743
|
+
font-size: var(--ab-cmp-adaptable-permitted-values-selector__font-size);
|
|
2744
|
+
border: 1px solid var(--ab-cmp-adaptable-permitted-values-selector__border);
|
|
2745
|
+
background-color: var(--ab-cmp-adaptable-permitted-values-selector__background-color);
|
|
2746
|
+
padding: var(--ab-cmp-adaptable-permitted-values-selector__padding); }
|
|
2747
|
+
|
|
2801
2748
|
.ab-Radio-input:focus + svg rect {
|
|
2802
2749
|
stroke: var(--ab-color-accent);
|
|
2803
2750
|
stroke-width: 2; }
|
|
@@ -4258,6 +4205,12 @@ button.ab-StatusBar__SubPanel:hover {
|
|
|
4258
4205
|
max-width: var(--ab-cmp-adaptable-layout-wizard-column-input__max-width);
|
|
4259
4206
|
width: var(--ab-cmp-adaptable-layout-wizard-column-input__width); }
|
|
4260
4207
|
|
|
4208
|
+
:root {
|
|
4209
|
+
--ab-cmp-adaptable-permitted-values-selector__font-size: var(--ab-font-size-2);
|
|
4210
|
+
--ab-cmp-adaptable-permitted-values-selector__border: 1px solid var(--ab-color-primarydark);
|
|
4211
|
+
--ab-cmp-adaptable-permitted-values-selector__background-color: var(--ab-color-defaultbackground);
|
|
4212
|
+
--ab-cmp-adaptable-permitted-values-selector__padding: var(--ab-space-1); }
|
|
4213
|
+
|
|
4261
4214
|
.ab-alert--error {
|
|
4262
4215
|
background: var(--ab-color-error); }
|
|
4263
4216
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adaptabletools/adaptable",
|
|
3
|
-
"version": "12.1.
|
|
3
|
+
"version": "12.1.8-canary.1",
|
|
4
4
|
"description": "Powerful data-agnostic HTML5 datagrid add-on that sits on top of an underlying grid component and provides all the rich functionality that advanced users expect from their DataGrids and Data Tables",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"web-components",
|
package/publishTimestamp.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default:
|
|
1
|
+
declare const _default: 1661375016938;
|
|
2
2
|
export default _default;
|
package/publishTimestamp.js
CHANGED
|
@@ -119,6 +119,7 @@ export interface IAdaptable {
|
|
|
119
119
|
_emitSync(eventName: 'CreateAdaptableContextMenuItems', data?: any): Promise<any>;
|
|
120
120
|
prepareGrid(): void;
|
|
121
121
|
redrawBody(): void;
|
|
122
|
+
redrawRenderedRows(): void;
|
|
122
123
|
redrawHeader(): void;
|
|
123
124
|
redrawRow(rowNode: RowNode): void;
|
|
124
125
|
redrawRows(rowNodes: RowNode[]): void;
|
|
@@ -187,6 +188,7 @@ export interface IAdaptable {
|
|
|
187
188
|
getVisibleRowNodes(): RowNode[];
|
|
188
189
|
getAllRowNodes(config?: {
|
|
189
190
|
includeGroupRows?: boolean;
|
|
191
|
+
filterFn?: (rowNode: RowNode) => boolean;
|
|
190
192
|
}): RowNode[];
|
|
191
193
|
getRowsInViewport(): RowNode[];
|
|
192
194
|
isGroupRowNode(rowNode: RowNode): boolean;
|
|
@@ -5,14 +5,12 @@ import { Column } from '@ag-grid-community/all-modules';
|
|
|
5
5
|
export interface ColumnOptions {
|
|
6
6
|
/**
|
|
7
7
|
* Provide an alternative Friendly Name for a Column
|
|
8
|
-
*
|
|
9
8
|
* @defaultValue undefined
|
|
10
9
|
*/
|
|
11
10
|
columnFriendlyName?: (columnFriendlyNameContext: ColumnFriendlyNameContext) => string | undefined;
|
|
12
11
|
/**
|
|
13
|
-
* Optional list of Column Types - used primarily for
|
|
14
|
-
*
|
|
15
|
-
* @defaultValue []
|
|
12
|
+
* Optional list of Column Types - used primarily for Calculated and FreeText Columns
|
|
13
|
+
* @defaultValue undefined
|
|
16
14
|
*/
|
|
17
15
|
columnTypes?: string[];
|
|
18
16
|
/**
|
|
@@ -157,4 +157,16 @@ export interface FilterOptions {
|
|
|
157
157
|
* @gridInfoItem
|
|
158
158
|
*/
|
|
159
159
|
showDistinctFilteredValuesOnly?: boolean;
|
|
160
|
+
/**
|
|
161
|
+
* Display Clear Filter button in Toolbar and Toolpanel
|
|
162
|
+
* @defaultValue false
|
|
163
|
+
* @gridInfoItem
|
|
164
|
+
*/
|
|
165
|
+
showClearFilterButton?: boolean;
|
|
166
|
+
/**
|
|
167
|
+
* Display Suspend / Unsuspend Button in Toolbar and Toolpanel
|
|
168
|
+
* @defaultValue false
|
|
169
|
+
* @gridInfoItem
|
|
170
|
+
*/
|
|
171
|
+
showSuspendFilterButton?: boolean;
|
|
160
172
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AdaptableIcon, ContextMenuContext, GridCell } from '../../types';
|
|
1
|
+
import { AdaptableApi, AdaptableIcon, ContextMenuContext, FDC3Context, GridCell } from '../../types';
|
|
2
2
|
import { CustomFDC3Context } from '../PredefinedConfig/Common/FDC3Context';
|
|
3
3
|
/**
|
|
4
4
|
* Options required for when using the Finance plugin
|
|
@@ -41,6 +41,18 @@ export interface FinancePluginOptions {
|
|
|
41
41
|
* Columns to use a Weighted Average aggregation
|
|
42
42
|
*/
|
|
43
43
|
weightedAverageColumns?: WeightedAverageColumn[];
|
|
44
|
+
/**
|
|
45
|
+
* Intents to which to subscribe.
|
|
46
|
+
*/
|
|
47
|
+
availableFDC3Intents?: (FDC3Intent | CustomFDC3Intent)[];
|
|
48
|
+
/**
|
|
49
|
+
* Called when an intent from `availableIntents` is raised.
|
|
50
|
+
*/
|
|
51
|
+
onFDC3Intent?: (intent: FDC3Intent | CustomFDC3Intent, context: FDC3Context, adaptableApi: AdaptableApi) => void;
|
|
52
|
+
/**
|
|
53
|
+
* Called when a context changes.
|
|
54
|
+
*/
|
|
55
|
+
onFDC3Context?: (context: FDC3Context, adaptableApi: AdaptableApi) => void;
|
|
44
56
|
}
|
|
45
57
|
/**
|
|
46
58
|
* An Column which contains a Weighted Average aggregation
|
|
@@ -265,3 +277,12 @@ export interface RaiseFDC3IntentContext extends ContextMenuContext {
|
|
|
265
277
|
*/
|
|
266
278
|
intent: FDC3Intent | CustomFDC3Intent;
|
|
267
279
|
}
|
|
280
|
+
export declare type FDC3ContextHandler = (context: FDC3Context) => void;
|
|
281
|
+
export interface FDC3DesktopAgent {
|
|
282
|
+
raiseIntent: (intent: FDC3Intent, context: FDC3Context) => void;
|
|
283
|
+
broadcast: (context: FDC3Context) => void;
|
|
284
|
+
addIntentListener: (intent: FDC3Intent | CustomFDC3Intent, listener: (context: FDC3Context) => void) => void;
|
|
285
|
+
addContextListener: (contextType: string | null, handler: FDC3ContextHandler) => {
|
|
286
|
+
unsubscribe: () => void;
|
|
287
|
+
};
|
|
288
|
+
}
|
|
@@ -4,7 +4,7 @@ import { AdaptableState } from '../PredefinedConfig/AdaptableState';
|
|
|
4
4
|
*/
|
|
5
5
|
export interface StateOptions {
|
|
6
6
|
/**
|
|
7
|
-
* Allows
|
|
7
|
+
* Allows customization of Adaptable State loading
|
|
8
8
|
*/
|
|
9
9
|
loadState?: AdaptableLoadStateFunction;
|
|
10
10
|
/**
|
|
@@ -12,11 +12,11 @@ export interface StateOptions {
|
|
|
12
12
|
*/
|
|
13
13
|
applyState?: (state: any) => any;
|
|
14
14
|
/**
|
|
15
|
-
* Allows
|
|
15
|
+
* Allows customization of Adaptable State about to be persisted
|
|
16
16
|
*/
|
|
17
17
|
saveState?: AdaptableSaveStateFunction;
|
|
18
18
|
/**
|
|
19
|
-
* Allows
|
|
19
|
+
* Allows customization of Adaptable State persistence
|
|
20
20
|
*/
|
|
21
21
|
persistState?: AdaptablePersistStateFunction;
|
|
22
22
|
/**
|
|
@@ -34,39 +34,52 @@ export interface StateOptions {
|
|
|
34
34
|
*/
|
|
35
35
|
debounceStateDelay?: number;
|
|
36
36
|
}
|
|
37
|
-
|
|
37
|
+
/**
|
|
38
|
+
* State Function Config object passed into all State Options functions (except 'applyState')
|
|
39
|
+
*/
|
|
40
|
+
export interface AdaptableStateFunctionConfig {
|
|
41
|
+
/**
|
|
42
|
+
* Id of current Adaptable instance
|
|
43
|
+
*/
|
|
38
44
|
adaptableId: string;
|
|
45
|
+
/**
|
|
46
|
+
* State Key being used
|
|
47
|
+
*/
|
|
39
48
|
adaptableStateKey: string;
|
|
49
|
+
/**
|
|
50
|
+
* current Adaptable user
|
|
51
|
+
*/
|
|
40
52
|
userName: string;
|
|
53
|
+
/**
|
|
54
|
+
* optional url
|
|
55
|
+
*/
|
|
41
56
|
url?: string;
|
|
42
|
-
}
|
|
57
|
+
}
|
|
43
58
|
/**
|
|
44
59
|
* Allows customization of state persistence - used `persistState` function in StateOptions
|
|
45
60
|
*
|
|
46
61
|
* @example
|
|
47
62
|
* ```
|
|
48
|
-
* persistState = (state,
|
|
49
|
-
* localStorage.setItem(adaptableStateKey, JSON.stringify(state))
|
|
63
|
+
* persistState = (state, stateFunctionConfig) => {
|
|
64
|
+
* localStorage.setItem(stateFunctionConfig.adaptableStateKey, JSON.stringify(state))
|
|
50
65
|
* }
|
|
51
66
|
* ```
|
|
52
67
|
*/
|
|
53
68
|
export interface AdaptablePersistStateFunction {
|
|
54
|
-
(state: any,
|
|
69
|
+
(state: any, adaptableStateFunctionConfig: AdaptableStateFunctionConfig): Promise<any>;
|
|
55
70
|
}
|
|
56
71
|
/**
|
|
57
72
|
* Allows clearing state when a custom persistState is used.
|
|
58
73
|
* Only called by configApi.reloadPredefinedConfig
|
|
59
|
-
*
|
|
60
|
-
* @example
|
|
61
74
|
*/
|
|
62
75
|
export interface AdaptableClearStateFunction {
|
|
63
|
-
(
|
|
76
|
+
(adaptablestatefunctionconfig: AdaptableStateFunctionConfig): Promise<any>;
|
|
64
77
|
}
|
|
65
78
|
/**
|
|
66
79
|
* Allows the customization state persistence - used by `saveState` function in StateOptions
|
|
67
80
|
*/
|
|
68
81
|
export interface AdaptableSaveStateFunction {
|
|
69
|
-
(state: AdaptableState,
|
|
82
|
+
(state: AdaptableState, adaptablestatefunctionconfig: AdaptableStateFunctionConfig): any;
|
|
70
83
|
}
|
|
71
84
|
/**
|
|
72
85
|
* Allows customization of state loading - used by `loadState` function in StateOptions
|
package/src/Api/ColumnApi.d.ts
CHANGED
|
@@ -308,6 +308,11 @@ export interface ColumnApi {
|
|
|
308
308
|
* @param columnId Column to Check
|
|
309
309
|
*/
|
|
310
310
|
getDefaultAggFunc(columnId: string): string;
|
|
311
|
+
/**
|
|
312
|
+
* Returns the `types` property for a given Column
|
|
313
|
+
* @param columnId Column to Check
|
|
314
|
+
*/
|
|
315
|
+
getTypesForColumn(columnId: string): string | string[];
|
|
311
316
|
getMinValueForNumericColumn(column: AdaptableColumn): number | undefined;
|
|
312
317
|
getMaxValueForNumericColumn(column: AdaptableColumn): number | undefined;
|
|
313
318
|
}
|
package/src/Api/ExportApi.d.ts
CHANGED
|
@@ -133,6 +133,11 @@ export interface ExportApi {
|
|
|
133
133
|
* Exports data currently in grid to Excel as What-You-See-Is-What-You-Get
|
|
134
134
|
*/
|
|
135
135
|
exportVisualDataToExcel(): void;
|
|
136
|
+
/**
|
|
137
|
+
* Whether a Report is a Custom Report
|
|
138
|
+
* @param customReportName Report to Check
|
|
139
|
+
*/
|
|
140
|
+
isCustomReport(report: Report): boolean;
|
|
136
141
|
/**
|
|
137
142
|
* Runs the report function of the CustomReport with the given reportName
|
|
138
143
|
* @param reportName custom report name
|
package/src/Api/FilterApi.d.ts
CHANGED
|
@@ -48,6 +48,11 @@ export interface FilterApi {
|
|
|
48
48
|
* @returns column filters
|
|
49
49
|
*/
|
|
50
50
|
getColumnFilters(): ColumnFilter[];
|
|
51
|
+
/**
|
|
52
|
+
* Retrieves all active/no-suspedned Column Filters in currently applied Layout
|
|
53
|
+
* @returns column filters
|
|
54
|
+
*/
|
|
55
|
+
getActiveColumnFilters(): ColumnFilter[];
|
|
51
56
|
/**
|
|
52
57
|
* Retrieves the Column Filter for the specified Column.
|
|
53
58
|
* @param columnId Column ID to lookup
|
|
@@ -144,4 +149,22 @@ export interface FilterApi {
|
|
|
144
149
|
* @param filters2
|
|
145
150
|
*/
|
|
146
151
|
areColumnFiltersDifferent(filters1: ColumnFilter[], filters2: ColumnFilter[]): boolean;
|
|
152
|
+
/**
|
|
153
|
+
* Suspends a Column Filter
|
|
154
|
+
* @param columnFilter Column Filter to Suspend
|
|
155
|
+
*/
|
|
156
|
+
suspendColumnFilter(columnFilter: ColumnFilter): void;
|
|
157
|
+
/**
|
|
158
|
+
* Unsuspends a Column Filter
|
|
159
|
+
* @param columnFilter Column Filter to UnSuspend
|
|
160
|
+
*/
|
|
161
|
+
unSuspendColumnFilter(columnFilter: ColumnFilter): void;
|
|
162
|
+
/**
|
|
163
|
+
* Suspends all Column Filters
|
|
164
|
+
*/
|
|
165
|
+
suspendAllColumnFilters(): void;
|
|
166
|
+
/**
|
|
167
|
+
* Unsuspends all Column Filters
|
|
168
|
+
*/
|
|
169
|
+
unSuspendAllColumnFilters(): void;
|
|
147
170
|
}
|
|
@@ -60,6 +60,10 @@ export interface FlashingCellApi {
|
|
|
60
60
|
* @param flashingCellDefinitions Flashing Cell Definitions to Add to State
|
|
61
61
|
*/
|
|
62
62
|
setFlashingCellDefinitions(flashingCellDefinitions: FlashingCellDefinition[]): void;
|
|
63
|
+
/**
|
|
64
|
+
* Merges a Flashing Cell Definition with default values
|
|
65
|
+
* @param flashingCellDefinition Flashing Cell Definition to Merge
|
|
66
|
+
*/
|
|
63
67
|
mergeFlashingCellDefinitionWithDefaults(flashingCellDefinition: FlashingCellDefinition): FlashingCellDefinition;
|
|
64
68
|
/**
|
|
65
69
|
* Adds provided Flashing cell Definitions
|
|
@@ -88,4 +92,8 @@ export interface FlashingCellApi {
|
|
|
88
92
|
* @param scope the Scope to check
|
|
89
93
|
*/
|
|
90
94
|
getFlashingCellPredicateDefsForScope(scope: AdaptableScope): AdaptablePredicateDef[];
|
|
95
|
+
/**
|
|
96
|
+
* Clears all Cells and Rows which have been flashed (primarily used if duration is 'Always')
|
|
97
|
+
*/
|
|
98
|
+
clearGridFlashing(): void;
|
|
91
99
|
}
|
package/src/Api/GridApi.d.ts
CHANGED
|
@@ -72,4 +72,5 @@ export declare class ColumnApiImpl extends ApiBase implements ColumnApi {
|
|
|
72
72
|
getDefaultAggFunc(columnId: string): string;
|
|
73
73
|
getMinValueForNumericColumn(column: AdaptableColumn): number | undefined;
|
|
74
74
|
getMaxValueForNumericColumn(column: AdaptableColumn): number | undefined;
|
|
75
|
+
getTypesForColumn(columnId: string): string | string[] | undefined;
|
|
75
76
|
}
|
|
@@ -291,7 +291,6 @@ class ColumnApiImpl extends ApiBase_1.ApiBase {
|
|
|
291
291
|
}
|
|
292
292
|
async getDistinctFilterDisplayValuesForColumn(columnId, filter, showFilteredRowsOnly) {
|
|
293
293
|
const abColumn = this.getColumnFromId(columnId);
|
|
294
|
-
console.log('getting for ', columnId);
|
|
295
294
|
if (abColumn == undefined) {
|
|
296
295
|
return {
|
|
297
296
|
values: [],
|
|
@@ -435,5 +434,10 @@ class ColumnApiImpl extends ApiBase_1.ApiBase {
|
|
|
435
434
|
// can we cache this in some way?
|
|
436
435
|
return Math.max(...this.getDistinctRawValuesForColumn(column.columnId));
|
|
437
436
|
}
|
|
437
|
+
getTypesForColumn(columnId) {
|
|
438
|
+
var _a;
|
|
439
|
+
const agGridColumn = this.getAgGridColumnForAdaptableColumn(columnId);
|
|
440
|
+
return (_a = agGridColumn === null || agGridColumn === void 0 ? void 0 : agGridColumn.getColDef()) === null || _a === void 0 ? void 0 : _a.type;
|
|
441
|
+
}
|
|
438
442
|
}
|
|
439
443
|
exports.ColumnApiImpl = ColumnApiImpl;
|
|
@@ -3,7 +3,7 @@ import { ExportState, Report, ReportData, ReportSchedule, SystemReportNames } fr
|
|
|
3
3
|
import { ApiBase } from './ApiBase';
|
|
4
4
|
import { AdaptableForm } from '../../PredefinedConfig/Common/AdaptableForm';
|
|
5
5
|
import { CellDataChangedInfo } from '../../PredefinedConfig/Common/CellDataChangedInfo';
|
|
6
|
-
import { CustomDestination, ExportFormContext } from '../../AdaptableOptions/ExportOptions';
|
|
6
|
+
import { CustomDestination, CustomReport, ExportFormContext } from '../../AdaptableOptions/ExportOptions';
|
|
7
7
|
import { ExportDestination } from '../../PredefinedConfig/Common/Enums';
|
|
8
8
|
export declare class ExportApiImpl extends ApiBase implements ExportApi {
|
|
9
9
|
getExportState(): ExportState;
|
|
@@ -30,6 +30,8 @@ export declare class ExportApiImpl extends ApiBase implements ExportApi {
|
|
|
30
30
|
editReports(reports: Report[]): Report[];
|
|
31
31
|
isDataChangeInReport(cellDataChangedInfo: CellDataChangedInfo, report: Report): boolean;
|
|
32
32
|
exportVisualDataToExcel(): void;
|
|
33
|
+
getAllCustomReports(): CustomReport[] | undefined;
|
|
34
|
+
isCustomReport(report: Report): boolean;
|
|
33
35
|
runCustomReport(customReportName: string): ReportData | undefined;
|
|
34
36
|
getReportDataForReport(reportName: string): ReportData | undefined;
|
|
35
37
|
}
|
|
@@ -7,6 +7,8 @@ const ApiBase_1 = require("./ApiBase");
|
|
|
7
7
|
const ModuleConstants = tslib_1.__importStar(require("../../Utilities/Constants/ModuleConstants"));
|
|
8
8
|
const Enums_1 = require("../../PredefinedConfig/Common/Enums");
|
|
9
9
|
const LoggingHelper_1 = require("../../Utilities/Helpers/LoggingHelper");
|
|
10
|
+
const ObjectFactory_1 = tslib_1.__importDefault(require("../../Utilities/ObjectFactory"));
|
|
11
|
+
const ArrayExtensions_1 = tslib_1.__importDefault(require("../../Utilities/Extensions/ArrayExtensions"));
|
|
10
12
|
class ExportApiImpl extends ApiBase_1.ApiBase {
|
|
11
13
|
getExportState() {
|
|
12
14
|
return this.getAdaptableState().Export;
|
|
@@ -56,9 +58,16 @@ class ExportApiImpl extends ApiBase_1.ApiBase {
|
|
|
56
58
|
return systemDestinations;
|
|
57
59
|
}
|
|
58
60
|
getAllReports() {
|
|
59
|
-
|
|
61
|
+
const reports = this.getAvailableSystemReports()
|
|
60
62
|
.map((s) => this.getReportByName(s))
|
|
61
63
|
.concat(this.getExportState().Reports);
|
|
64
|
+
const customReports = this.getAllCustomReports();
|
|
65
|
+
if (ArrayExtensions_1.default.IsNotNullOrEmpty(customReports)) {
|
|
66
|
+
reports.push(...customReports.map((c) => {
|
|
67
|
+
return ObjectFactory_1.default.CreateCustomReport(c.name);
|
|
68
|
+
}));
|
|
69
|
+
}
|
|
70
|
+
return reports;
|
|
62
71
|
}
|
|
63
72
|
getReportSchedules() {
|
|
64
73
|
return this.getAdaptableState().Schedule.ReportSchedules;
|
|
@@ -111,7 +120,7 @@ class ExportApiImpl extends ApiBase_1.ApiBase {
|
|
|
111
120
|
return true;
|
|
112
121
|
}
|
|
113
122
|
// if its a Custom Report then the User has to run it so we just ignore completely
|
|
114
|
-
if (
|
|
123
|
+
if (this.isCustomReport(report)) {
|
|
115
124
|
return false;
|
|
116
125
|
}
|
|
117
126
|
// Start with the DataChanged Column and go through all possibilities
|
|
@@ -169,9 +178,16 @@ class ExportApiImpl extends ApiBase_1.ApiBase {
|
|
|
169
178
|
exportVisualDataToExcel() {
|
|
170
179
|
this.adaptable.exportVisualDataToExcel();
|
|
171
180
|
}
|
|
181
|
+
getAllCustomReports() {
|
|
182
|
+
return this.getExportOptions().customReports;
|
|
183
|
+
}
|
|
184
|
+
isCustomReport(report) {
|
|
185
|
+
var _a;
|
|
186
|
+
return ((_a = this.getAllCustomReports()) === null || _a === void 0 ? void 0 : _a.find((cr) => cr.name == report.Name)) != null;
|
|
187
|
+
}
|
|
172
188
|
runCustomReport(customReportName) {
|
|
173
189
|
var _a;
|
|
174
|
-
const customReport = (_a = this.
|
|
190
|
+
const customReport = (_a = this.getAllCustomReports()) === null || _a === void 0 ? void 0 : _a.find((cr) => cr.name == customReportName);
|
|
175
191
|
if (!customReport) {
|
|
176
192
|
LoggingHelper_1.LogAdaptableWarning(`Custom Report '${customReportName}' not found!`);
|
|
177
193
|
return undefined;
|
|
@@ -17,6 +17,7 @@ export declare class FilterApiImpl extends ApiBase implements FilterApi {
|
|
|
17
17
|
isQuickFilterAvailable(): boolean;
|
|
18
18
|
isQuickFilterVisible(): boolean;
|
|
19
19
|
getColumnFilters(): ColumnFilter[];
|
|
20
|
+
getActiveColumnFilters(): ColumnFilter[];
|
|
20
21
|
getColumnFilter(columnId: string): ColumnFilter | undefined;
|
|
21
22
|
getColumnFilterDefs(): ColumnFilterDef[];
|
|
22
23
|
getColumnFiltersForLayout(layoutName: string): ColumnFilter[];
|
|
@@ -44,4 +45,8 @@ export declare class FilterApiImpl extends ApiBase implements FilterApi {
|
|
|
44
45
|
shouldNewColumnFilterTriggerGridFiltering(action: LayoutRedux.LayoutColumnFilterAction | Redux.Action): boolean;
|
|
45
46
|
areColumnFiltersDifferent(oldFilters: ColumnFilter[], newFilters: ColumnFilter[]): boolean;
|
|
46
47
|
fireFilterAppliedEvent(): void;
|
|
48
|
+
suspendColumnFilter(columnFilter: ColumnFilter): void;
|
|
49
|
+
unSuspendColumnFilter(columnFilter: ColumnFilter): void;
|
|
50
|
+
suspendAllColumnFilters(): void;
|
|
51
|
+
unSuspendAllColumnFilters(): void;
|
|
47
52
|
}
|
|
@@ -47,6 +47,9 @@ class FilterApiImpl extends ApiBase_1.ApiBase {
|
|
|
47
47
|
const currentLayout = this.adaptable.api.layoutApi.getCurrentLayout();
|
|
48
48
|
return (_a = currentLayout.ColumnFilters) !== null && _a !== void 0 ? _a : [];
|
|
49
49
|
}
|
|
50
|
+
getActiveColumnFilters() {
|
|
51
|
+
return this.getColumnFilters().filter((columnFilter) => !columnFilter.IsSuspended);
|
|
52
|
+
}
|
|
50
53
|
getColumnFilter(columnId) {
|
|
51
54
|
return this.getColumnFilters().find((columnFilter) => columnFilter.ColumnId == columnId);
|
|
52
55
|
}
|
|
@@ -176,7 +179,16 @@ class FilterApiImpl extends ApiBase_1.ApiBase {
|
|
|
176
179
|
if (!columnFilter.Predicate) {
|
|
177
180
|
return true;
|
|
178
181
|
}
|
|
179
|
-
|
|
182
|
+
const someInputsAreEmpty = (_a = columnFilter.Predicate.Inputs) === null || _a === void 0 ? void 0 : _a.some((input) => {
|
|
183
|
+
if (typeof input === 'string') {
|
|
184
|
+
return StringExtensions_1.default.IsNullOrEmpty(input);
|
|
185
|
+
}
|
|
186
|
+
if (typeof input === 'number') {
|
|
187
|
+
return isNaN(input);
|
|
188
|
+
}
|
|
189
|
+
return !input;
|
|
190
|
+
});
|
|
191
|
+
if (someInputsAreEmpty) {
|
|
180
192
|
return true;
|
|
181
193
|
}
|
|
182
194
|
const column = this.adaptable.api.columnApi.getColumnFromId(columnFilter.ColumnId);
|
|
@@ -228,7 +240,6 @@ class FilterApiImpl extends ApiBase_1.ApiBase {
|
|
|
228
240
|
return allInputsHaveValues;
|
|
229
241
|
}
|
|
230
242
|
shouldNewColumnFilterTriggerGridFiltering(action) {
|
|
231
|
-
var _a, _b;
|
|
232
243
|
// trigger filter change only:
|
|
233
244
|
// - new -> new filter is active
|
|
234
245
|
// - clear -> previous filters was active
|
|
@@ -237,6 +248,8 @@ class FilterApiImpl extends ApiBase_1.ApiBase {
|
|
|
237
248
|
// - edit -> different & new is active
|
|
238
249
|
// - edit -> different & old was active
|
|
239
250
|
// - set -> new filter is active
|
|
251
|
+
// filter -> suspend changes
|
|
252
|
+
var _a, _b;
|
|
240
253
|
const isNewAndActive = action.type === LayoutRedux.LAYOUT_COLUMN_FILTER_ADD &&
|
|
241
254
|
this.adaptable.api.filterApi.isFilterActive(action.columnFilter);
|
|
242
255
|
const isClearAndPreviousWasActive = action.type === LayoutRedux.LAYOUT_COLUMN_FILTER_CLEAR &&
|
|
@@ -264,11 +277,18 @@ class FilterApiImpl extends ApiBase_1.ApiBase {
|
|
|
264
277
|
}
|
|
265
278
|
const isSetAndActive = action.type === LayoutRedux.LAYOUT_COLUMN_FILTER_SET &&
|
|
266
279
|
this.adaptable.api.filterApi.isFilterActive(action.columnFilter);
|
|
280
|
+
const isSuspendChanged = [
|
|
281
|
+
LayoutRedux.LAYOUT_COLUMN_FILTER_SUSPEND,
|
|
282
|
+
LayoutRedux.LAYOUT_COLUMN_FILTER_SUSPEND_ALL,
|
|
283
|
+
LayoutRedux.LAYOUT_COLUMN_FILTER_UNSUSPEND,
|
|
284
|
+
LayoutRedux.LAYOUT_COLUMN_FILTER_UNSUSPEND_ALL,
|
|
285
|
+
].includes(action.type);
|
|
267
286
|
return (isNewAndActive ||
|
|
268
287
|
isClearAndPreviousWasActive ||
|
|
269
288
|
isClearAllAtLeastOneActiveFilter ||
|
|
270
289
|
isEditTrigger ||
|
|
271
|
-
isSetAndActive
|
|
290
|
+
isSetAndActive ||
|
|
291
|
+
isSuspendChanged);
|
|
272
292
|
}
|
|
273
293
|
areColumnFiltersDifferent(oldFilters, newFilters) {
|
|
274
294
|
if (ArrayExtensions_1.default.IsNullOrEmpty(oldFilters) && ArrayExtensions_1.default.IsNullOrEmpty(newFilters)) {
|
|
@@ -285,5 +305,17 @@ class FilterApiImpl extends ApiBase_1.ApiBase {
|
|
|
285
305
|
this.adaptable.api.eventApi.emit('FilterApplied', filterAppliedInfo);
|
|
286
306
|
}
|
|
287
307
|
}
|
|
308
|
+
suspendColumnFilter(columnFilter) {
|
|
309
|
+
this.adaptable.api.internalApi.dispatchReduxAction(LayoutRedux.LayoutColumnFilterSuspend(columnFilter));
|
|
310
|
+
}
|
|
311
|
+
unSuspendColumnFilter(columnFilter) {
|
|
312
|
+
this.adaptable.api.internalApi.dispatchReduxAction(LayoutRedux.LayoutColumnFilterUnSuspend(columnFilter));
|
|
313
|
+
}
|
|
314
|
+
suspendAllColumnFilters() {
|
|
315
|
+
this.adaptable.api.internalApi.dispatchReduxAction(LayoutRedux.LayoutColumnFilterSuspendAll());
|
|
316
|
+
}
|
|
317
|
+
unSuspendAllColumnFilters() {
|
|
318
|
+
this.adaptable.api.internalApi.dispatchReduxAction(LayoutRedux.LayoutColumnFilterUnSuspendAll());
|
|
319
|
+
}
|
|
288
320
|
}
|
|
289
321
|
exports.FilterApiImpl = FilterApiImpl;
|
|
@@ -21,4 +21,5 @@ export declare class FlashingCellApiImpl extends ApiBase implements FlashingCell
|
|
|
21
21
|
editFlashingCellDefinitions(flashingCellDefinitions: FlashingCellDefinition[]): FlashingCellDefinition[];
|
|
22
22
|
getFlashingCellPredicateDefs(): AdaptablePredicateDef[];
|
|
23
23
|
getFlashingCellPredicateDefsForScope(scope: AdaptableScope): AdaptablePredicateDef[];
|
|
24
|
+
clearGridFlashing(): void;
|
|
24
25
|
}
|
|
@@ -106,5 +106,9 @@ class FlashingCellApiImpl extends ApiBase_1.ApiBase {
|
|
|
106
106
|
getFlashingCellPredicateDefsForScope(scope) {
|
|
107
107
|
return this.getFlashingCellPredicateDefs().filter((predicateDef) => this.adaptable.api.scopeApi.isScopeInScope(scope, predicateDef.columnScope));
|
|
108
108
|
}
|
|
109
|
+
clearGridFlashing() {
|
|
110
|
+
const currentFlashingCells = this.getAdaptableState().System.AdaptableFlashingCells;
|
|
111
|
+
this.dispatchAction(SystemRedux.SystemFlashingCellDeleteAll());
|
|
112
|
+
}
|
|
109
113
|
}
|
|
110
114
|
exports.FlashingCellApiImpl = FlashingCellApiImpl;
|
|
@@ -61,6 +61,7 @@ export declare class GridApiImpl extends ApiBase implements GridApi {
|
|
|
61
61
|
getVisibleRowNodes(): RowNode[];
|
|
62
62
|
getAllRowNodes(config: {
|
|
63
63
|
includeGroupRows?: boolean;
|
|
64
|
+
filterFn?: (rowNode: RowNode) => boolean;
|
|
64
65
|
}): RowNode[];
|
|
65
66
|
getGridCellFromRowNode(rowNode: RowNode, columnId: string): GridCell | undefined;
|
|
66
67
|
getRawValueFromRowNode(rowNode: RowNode, columnId: string): any | undefined;
|
|
@@ -61,7 +61,6 @@ export declare class InternalApiImpl extends ApiBase implements InternalApi {
|
|
|
61
61
|
[key: string]: any;
|
|
62
62
|
}): void;
|
|
63
63
|
hidePopupScreen(): void;
|
|
64
|
-
hidePopupAlert(): void;
|
|
65
64
|
setColumns(columns: AdaptableColumn[]): void;
|
|
66
65
|
setSettingPanelModuleMenuItems(menuItems: AdaptableMenuItem[]): void;
|
|
67
66
|
setModuleButtonMenuItems(menuItems: AdaptableMenuItem[]): void;
|
|
@@ -149,9 +149,6 @@ class InternalApiImpl extends ApiBase_1.ApiBase {
|
|
|
149
149
|
hidePopupScreen() {
|
|
150
150
|
this.dispatchAction(PopupRedux.PopupHideScreen());
|
|
151
151
|
}
|
|
152
|
-
hidePopupAlert() {
|
|
153
|
-
this.dispatchAction(PopupRedux.PopupHideAlert());
|
|
154
|
-
}
|
|
155
152
|
setColumns(columns) {
|
|
156
153
|
this.dispatchAction(GridRedux.GridSetColumns(columns));
|
|
157
154
|
}
|
|
@@ -56,6 +56,10 @@ class PredicateApiImpl extends ApiBase_1.ApiBase {
|
|
|
56
56
|
return false;
|
|
57
57
|
}
|
|
58
58
|
}
|
|
59
|
+
if (['Values', 'ExcludeValues'].includes(predicate.PredicateId) &&
|
|
60
|
+
ArrayExtensions_1.default.IsNullOrEmpty(predicate.Inputs)) {
|
|
61
|
+
return false;
|
|
62
|
+
}
|
|
59
63
|
return true;
|
|
60
64
|
}
|
|
61
65
|
handlePredicate(predicate, params, defaultReturn) {
|
|
@@ -48,9 +48,17 @@ class QueryLanguageApiImpl extends ApiBase_1.ApiBase {
|
|
|
48
48
|
}
|
|
49
49
|
getColumnsFromExpression(expression) {
|
|
50
50
|
try {
|
|
51
|
-
|
|
51
|
+
const columnIds = this.adaptable.api.internalApi
|
|
52
52
|
.getQueryLanguageService()
|
|
53
53
|
.getColumnsFromExpression(expression);
|
|
54
|
+
columnIds.forEach((columnId) => {
|
|
55
|
+
const calculatedColumn = this.adaptable.api.calculatedColumnApi.getCalculatedColumnForColumnId(columnId);
|
|
56
|
+
if (calculatedColumn) {
|
|
57
|
+
const transitiveColumnIds = this.getColumnsFromExpression(this.getAdaptableQueryExpression(calculatedColumn.Query));
|
|
58
|
+
columnIds.push(...transitiveColumnIds);
|
|
59
|
+
}
|
|
60
|
+
});
|
|
61
|
+
return Array.from(new Set(columnIds));
|
|
54
62
|
}
|
|
55
63
|
catch (error) {
|
|
56
64
|
// defensive programing, this should happen only if someone botched the predefined configs
|