@adaptabletools/adaptable 18.0.0-canary.2 → 18.0.0-canary.21
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/agGrid.d.ts +4 -21
- package/agGrid.js +9 -26
- package/base.css +22 -8
- package/base.css.map +1 -1
- package/index.css +101 -75
- package/index.css.map +1 -1
- package/package.json +4 -5
- package/src/AdaptableInterfaces/IAdaptable.d.ts +59 -108
- package/src/AdaptableOptions/AdaptableOptions.d.ts +7 -7
- package/src/AdaptableOptions/ColumnFilterOptions.d.ts +11 -4
- package/src/AdaptableOptions/ColumnOptions.d.ts +9 -4
- package/src/AdaptableOptions/CommentOptions.d.ts +33 -0
- package/src/AdaptableOptions/GroupingOptions.d.ts +0 -7
- package/src/AdaptableOptions/MenuOptions.d.ts +6 -54
- package/src/AdaptableOptions/MenuOptions.js +71 -74
- package/src/AdaptableOptions/{NotesOptions.d.ts → NoteOptions.d.ts} +7 -4
- package/src/AdaptableOptions/StateOptions.d.ts +6 -0
- package/src/AdaptableOptions/UserInterfaceOptions.d.ts +17 -0
- package/src/Api/AdaptableApi.d.ts +9 -4
- package/src/Api/BulkUpdateApi.d.ts +0 -5
- package/src/Api/ColumnApi.d.ts +4 -0
- package/src/Api/CommentApi.d.ts +13 -14
- package/src/Api/ConfigApi.d.ts +4 -5
- package/src/Api/EventApi.d.ts +7 -9
- package/src/Api/Events/AdaptableReady.d.ts +3 -3
- package/src/Api/Events/CommentChanged.d.ts +11 -0
- package/src/Api/Events/GridDataChanged.d.ts +4 -4
- package/src/Api/GridApi.d.ts +23 -13
- package/src/Api/Implementation/ActionColumnApiImpl.d.ts +2 -0
- package/src/Api/Implementation/ActionColumnApiImpl.js +30 -0
- package/src/Api/Implementation/AdaptableApiImpl.d.ts +3 -2
- package/src/Api/Implementation/AdaptableApiImpl.js +5 -2
- package/src/Api/Implementation/ApiBase.d.ts +5 -3
- package/src/Api/Implementation/ApiBase.js +8 -2
- package/src/Api/Implementation/BulkUpdateApiImpl.d.ts +0 -1
- package/src/Api/Implementation/BulkUpdateApiImpl.js +0 -4
- package/src/Api/Implementation/CellSummaryApiImpl.d.ts +0 -5
- package/src/Api/Implementation/CellSummaryApiImpl.js +2 -23
- package/src/Api/Implementation/ColumnApiImpl.d.ts +1 -0
- package/src/Api/Implementation/ColumnApiImpl.js +10 -0
- package/src/Api/Implementation/CommentsApiImpl.d.ts +5 -2
- package/src/Api/Implementation/CommentsApiImpl.js +7 -1
- package/src/Api/Implementation/ConfigApiImpl.d.ts +2 -2
- package/src/Api/Implementation/ConfigApiImpl.js +24 -13
- package/src/Api/Implementation/GridApiImpl.d.ts +6 -3
- package/src/Api/Implementation/GridApiImpl.js +51 -14
- package/src/Api/Implementation/LayoutApiImpl.d.ts +3 -0
- package/src/Api/Implementation/LayoutApiImpl.js +18 -0
- package/src/Api/Implementation/NoteApiImpl.d.ts +18 -0
- package/src/Api/Implementation/NoteApiImpl.js +40 -0
- package/src/Api/Implementation/OptionsApiImpl.d.ts +4 -4
- package/src/Api/Implementation/OptionsApiImpl.js +4 -4
- package/src/Api/Implementation/ScopeApiImpl.d.ts +2 -0
- package/src/Api/Implementation/ScopeApiImpl.js +20 -7
- package/src/Api/Implementation/StatusBarApiImpl.d.ts +0 -1
- package/src/Api/Implementation/StatusBarApiImpl.js +0 -3
- package/src/Api/Implementation/ToolPanelApiImpl.js +6 -6
- package/src/Api/Implementation/UserInterfaceApiImpl.d.ts +0 -3
- package/src/Api/Implementation/UserInterfaceApiImpl.js +0 -8
- package/src/Api/Internal/ActionRowInternalApi.d.ts +6 -1
- package/src/Api/Internal/ActionRowInternalApi.js +118 -1
- package/src/Api/Internal/AdaptableInternalApi.d.ts +6 -7
- package/src/Api/Internal/AdaptableInternalApi.js +21 -19
- package/src/Api/Internal/CalculatedColumnInternalApi.d.ts +2 -0
- package/src/Api/Internal/CalculatedColumnInternalApi.js +71 -0
- package/src/Api/Internal/ColumnFilterInternalApi.d.ts +2 -0
- package/src/Api/Internal/ColumnFilterInternalApi.js +23 -1
- package/src/Api/Internal/ColumnInternalApi.d.ts +4 -1
- package/src/Api/Internal/ColumnInternalApi.js +12 -0
- package/src/Api/Internal/CommentsInternalApi.d.ts +4 -0
- package/src/Api/Internal/CommentsInternalApi.js +14 -0
- package/src/Api/Internal/CustomSortInternalApi.d.ts +3 -2
- package/src/Api/Internal/CustomSortInternalApi.js +32 -1
- package/src/Api/Internal/DataSetInternalApi.js +1 -1
- package/src/Api/Internal/ExportInternalApi.d.ts +2 -1
- package/src/Api/Internal/ExportInternalApi.js +4 -1
- package/src/Api/Internal/Fdc3InternalApi.js +2 -2
- package/src/Api/Internal/FormatColumnInternalApi.js +3 -2
- package/src/Api/Internal/FreeTextColumnInternalApi.d.ts +2 -0
- package/src/Api/Internal/FreeTextColumnInternalApi.js +60 -0
- package/src/Api/Internal/GridFilterInternalApi.d.ts +5 -0
- package/src/Api/Internal/GridFilterInternalApi.js +7 -1
- package/src/Api/Internal/GridInternalApi.d.ts +23 -3
- package/src/Api/Internal/GridInternalApi.js +141 -7
- package/src/Api/Internal/LayoutInternalApi.d.ts +1 -0
- package/src/Api/Internal/LayoutInternalApi.js +16 -0
- package/src/Api/Internal/NoteInternalApi.d.ts +4 -0
- package/src/Api/Internal/NoteInternalApi.js +14 -0
- package/src/Api/Internal/TeamSharingInternalApi.js +1 -1
- package/src/Api/InteropioPluginApi.d.ts +2 -2
- package/src/Api/LayoutApi.d.ts +15 -0
- package/src/Api/NoteApi.d.ts +48 -0
- package/src/Api/OptionsApi.d.ts +8 -8
- package/src/Api/ScopeApi.d.ts +10 -0
- package/src/Api/UserInterfaceApi.d.ts +0 -11
- package/src/EnvVars.d.ts +3 -0
- package/src/EnvVars.js +4 -0
- package/src/PredefinedConfig/AdaptableState.d.ts +2 -2
- package/src/PredefinedConfig/CommentState.d.ts +27 -23
- package/src/PredefinedConfig/Common/AdaptableColumn.d.ts +4 -0
- package/src/PredefinedConfig/Common/AdaptableIcon.d.ts +1 -1
- package/src/PredefinedConfig/Common/AdaptableScope.d.ts +4 -1
- package/src/PredefinedConfig/Common/AggregationColumns.d.ts +1 -0
- package/src/PredefinedConfig/Common/AggregationColumns.js +3 -0
- package/src/PredefinedConfig/Common/DataUpdateConfig.d.ts +4 -0
- package/src/PredefinedConfig/Common/Enums.d.ts +2 -1
- package/src/PredefinedConfig/Common/Enums.js +1 -0
- package/src/PredefinedConfig/Common/Menu.d.ts +15 -1
- package/src/PredefinedConfig/Common/Menu.js +97 -1
- package/src/PredefinedConfig/Common/RowSummary.d.ts +21 -0
- package/src/PredefinedConfig/Common/RowSummary.js +17 -0
- package/src/PredefinedConfig/Common/TransposeConfig.d.ts +30 -0
- package/src/PredefinedConfig/Common/Types.d.ts +4 -4
- package/src/PredefinedConfig/Common/Types.js +4 -1
- package/src/PredefinedConfig/LayoutState.d.ts +5 -0
- package/src/PredefinedConfig/{NotesState.d.ts → NoteState.d.ts} +12 -22
- package/src/PredefinedConfig/PredefinedConfig.d.ts +3 -3
- package/src/PredefinedConfig/Selection/GridCell.d.ts +13 -0
- package/src/PredefinedConfig/SystemState.d.ts +9 -3
- package/src/Redux/ActionsReducers/LayoutRedux.d.ts +9 -0
- package/src/Redux/ActionsReducers/LayoutRedux.js +32 -10
- package/src/Redux/ActionsReducers/NoteRedux.d.ts +38 -0
- package/src/Redux/ActionsReducers/{NotesRedux.js → NoteRedux.js} +29 -28
- package/src/Redux/ActionsReducers/SystemRedux.d.ts +6 -1
- package/src/Redux/ActionsReducers/SystemRedux.js +16 -4
- package/src/Redux/Store/AdaptableStore.d.ts +4 -6
- package/src/Redux/Store/AdaptableStore.js +67 -77
- package/src/Redux/Store/Interface/IAdaptableStore.d.ts +8 -2
- package/src/Strategy/AdaptableModuleBase.d.ts +8 -8
- package/src/Strategy/AdaptableModuleBase.js +13 -15
- package/src/Strategy/AlertModule.d.ts +1 -2
- package/src/Strategy/AlertModule.js +3 -56
- package/src/Strategy/BulkUpdateModule.js +1 -1
- package/src/Strategy/CalculatedColumnModule.d.ts +2 -3
- package/src/Strategy/CalculatedColumnModule.js +6 -26
- package/src/Strategy/CellSummaryModule.d.ts +8 -6
- package/src/Strategy/CellSummaryModule.js +78 -23
- package/src/Strategy/ChartingModule.d.ts +0 -1
- package/src/Strategy/ChartingModule.js +2 -22
- package/src/Strategy/ColumnFilterModule.d.ts +2 -3
- package/src/Strategy/ColumnFilterModule.js +44 -103
- package/src/Strategy/ColumnInfoModule.js +2 -0
- package/src/Strategy/{CommentsModule.d.ts → CommentModule.d.ts} +2 -5
- package/src/Strategy/{CommentsModule.js → CommentModule.js} +17 -23
- package/src/Strategy/CustomSortModule.js +3 -2
- package/src/Strategy/DashboardModule.d.ts +1 -2
- package/src/Strategy/DashboardModule.js +9 -15
- package/src/Strategy/DataChangeHistoryModule.d.ts +1 -0
- package/src/Strategy/DataChangeHistoryModule.js +3 -1
- package/src/Strategy/DataImportModule.d.ts +1 -1
- package/src/Strategy/DataImportModule.js +5 -5
- package/src/Strategy/DataSetModule.d.ts +1 -1
- package/src/Strategy/DataSetModule.js +1 -1
- package/src/Strategy/ExportModule.d.ts +1 -0
- package/src/Strategy/ExportModule.js +17 -2
- package/src/Strategy/Fdc3Module.js +3 -0
- package/src/Strategy/FlashingCellModule.d.ts +1 -2
- package/src/Strategy/FlashingCellModule.js +6 -19
- package/src/Strategy/FormatColumnModule.d.ts +0 -2
- package/src/Strategy/FormatColumnModule.js +6 -51
- package/src/Strategy/FreeTextColumnModule.d.ts +0 -1
- package/src/Strategy/FreeTextColumnModule.js +1 -31
- package/src/Strategy/GridFilterModule.d.ts +0 -1
- package/src/Strategy/GridFilterModule.js +0 -37
- package/src/Strategy/GridInfoModule.js +2 -0
- package/src/Strategy/Interface/IModule.d.ts +0 -1
- package/src/Strategy/LayoutModule.d.ts +9 -3
- package/src/Strategy/LayoutModule.js +148 -62
- package/src/Strategy/NamedQueryModule.d.ts +0 -1
- package/src/Strategy/NamedQueryModule.js +0 -19
- package/src/Strategy/{NotesModule.d.ts → NoteModule.d.ts} +2 -1
- package/src/Strategy/NoteModule.js +57 -0
- package/src/Strategy/PlusMinusModule.d.ts +1 -1
- package/src/Strategy/PlusMinusModule.js +2 -2
- package/src/Strategy/ScheduleModule.d.ts +1 -1
- package/src/Strategy/ScheduleModule.js +1 -1
- package/src/Strategy/SettingsPanelModule.js +3 -3
- package/src/Strategy/ShortcutModule.d.ts +1 -1
- package/src/Strategy/ShortcutModule.js +1 -1
- package/src/Strategy/SmartEditModule.js +1 -1
- package/src/Strategy/StyledColumnModule.d.ts +1 -1
- package/src/Strategy/StyledColumnModule.js +26 -26
- package/src/Strategy/SystemStatusModule.js +2 -2
- package/src/Strategy/TeamSharingModule.d.ts +1 -0
- package/src/Strategy/TeamSharingModule.js +5 -5
- package/src/Strategy/ToolPanelModule.d.ts +0 -1
- package/src/Strategy/ToolPanelModule.js +0 -23
- package/src/Strategy/Utilities/getScopeViewItems.js +3 -0
- package/src/Utilities/Constants/DocumentationLinkConstants.js +1 -1
- package/src/Utilities/Constants/GeneralConstants.d.ts +1 -0
- package/src/Utilities/Constants/GeneralConstants.js +1 -0
- package/src/Utilities/Constants/ModuleConstants.d.ts +6 -6
- package/src/Utilities/Constants/ModuleConstants.js +6 -6
- package/src/Utilities/Defaults/DefaultSettingsPanel.js +7 -6
- package/src/Utilities/ExpressionFunctions/aggregatedScalarExpressionFunctions.d.ts +3 -2
- package/src/Utilities/ExpressionFunctions/aggregatedScalarExpressionFunctions.js +429 -1
- package/src/Utilities/ExpressionFunctions/observableExpressionFunctions.js +3 -3
- package/src/Utilities/ExpressionFunctions/scalarAggregationHelper.js +1 -1
- package/src/Utilities/ExpressionFunctions/scalarExpressionFunctions.d.ts +1 -1
- package/src/Utilities/ExpressionFunctions/scalarExpressionFunctions.js +15 -0
- package/src/Utilities/Extensions/ArrayExtensions.d.ts +2 -0
- package/src/Utilities/Extensions/ArrayExtensions.js +4 -0
- package/src/Utilities/Helpers/AdaptableHelper.d.ts +3 -4
- package/src/Utilities/Helpers/AdaptableHelper.js +18 -58
- package/src/Utilities/Helpers/Helper.d.ts +2 -0
- package/src/Utilities/Helpers/Helper.js +4 -0
- package/src/Utilities/MenuItem.d.ts +7 -4
- package/src/Utilities/MenuItem.js +6 -3
- package/src/Utilities/ObjectFactory.d.ts +3 -3
- package/src/Utilities/ObjectFactory.js +4 -24
- package/src/Utilities/Services/AggregatedScalarLiveValue.d.ts +4 -2
- package/src/Utilities/Services/AggregatedScalarLiveValue.js +26 -19
- package/src/Utilities/Services/CellPopupService.js +2 -3
- package/src/Utilities/Services/Interface/IQueryLanguageService.d.ts +1 -1
- package/src/Utilities/Services/Interface/IReportService.d.ts +1 -4
- package/src/Utilities/Services/LicenseService/index.d.ts +3 -0
- package/src/Utilities/Services/LicenseService/index.js +1 -181
- package/src/Utilities/Services/MetamodelService.d.ts +1 -1
- package/src/Utilities/Services/MetamodelService.js +6 -3
- package/src/Utilities/Services/ModuleService.js +4 -0
- package/src/Utilities/Services/QueryLanguageService.d.ts +1 -1
- package/src/Utilities/Services/QueryLanguageService.js +4 -3
- package/src/Utilities/Services/ReportService.d.ts +7 -5
- package/src/Utilities/Services/ReportService.js +238 -22
- package/src/Utilities/Services/RowEditService.d.ts +3 -2
- package/src/Utilities/Services/RowEditService.js +3 -1
- package/src/Utilities/adaptableQlUtils.d.ts +2 -0
- package/src/Utilities/adaptableQlUtils.js +14 -0
- package/src/Utilities/license/decode.js +1 -65
- package/src/Utilities/license/hashing.js +1 -43
- package/src/View/AdaptableView.js +1 -3
- package/src/View/AdaptableViewFactory.js +2 -2
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/ConfigurationWizard.js +2 -2
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/UIOptions/UIOptionsStatusbarForm.js +1 -1
- package/src/View/BulkUpdate/BulkUpdatePopup.js +1 -1
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnWizard.js +3 -3
- package/src/View/CalculatedColumn/utils.d.ts +1 -1
- package/src/View/CellSummary/CellSummaryPopup.js +1 -1
- package/src/View/Comments/CommentsEditor.js +24 -11
- package/src/View/Comments/CommentsPopup.js +20 -11
- package/src/View/Components/AdaptableDateInput/index.d.ts +1 -1
- package/src/View/Components/AdaptableInput/AdaptableDateInlineInput.d.ts +5 -0
- package/src/View/Components/AdaptableInput/AdaptableDateInlineInput.js +42 -0
- package/src/View/Components/AdaptableObjectList/AdaptableObjectList.js +5 -2
- package/src/View/Components/CellPopup/index.d.ts +1 -0
- package/src/View/Components/CellPopup/index.js +5 -2
- package/src/View/Components/FilterForm/FilterForm.js +20 -12
- package/src/View/Components/FilterForm/QuickFilterForm.js +15 -8
- package/src/View/Components/FilterForm/QuickFilterValues.js +39 -23
- package/src/View/Components/NewScopeComponent.js +34 -1
- package/src/View/Components/Popups/AdaptableLoadingScreen.d.ts +6 -5
- package/src/View/Components/Popups/AdaptableLoadingScreen.js +19 -9
- package/src/View/Components/Popups/AdaptableToaster.js +1 -1
- package/src/View/Components/Popups/GridCellPopup/GridCellPopup.js +7 -7
- package/src/View/Components/Popups/WindowPopups/windowFactory.d.ts +1 -0
- package/src/View/Components/Popups/WindowPopups/windowFactory.js +3 -0
- package/src/View/Components/Selectors/PermittedValuesSelector.js +2 -2
- package/src/View/Components/ValueSelector/index.d.ts +1 -0
- package/src/View/Components/ValueSelector/index.js +2 -2
- package/src/View/CustomSort/CustomSortSummary.js +1 -1
- package/src/View/DataChangeHistory/DataChangeHistoryGrid.js +8 -9
- package/src/View/FreeTextColumn/FreeTextColumnSummary.js +1 -1
- package/src/View/FreeTextColumn/Wizard/FreeTextColumnWizard.js +3 -1
- package/src/View/GridFilter/GridFilterViewPanel.js +9 -5
- package/src/View/GridFilter/useGridFilterExpressionEditor.js +1 -1
- package/src/View/GridInfo/GridInfoPopup/GridInfoPopup.js +2 -3
- package/src/View/Layout/LayoutViewPanel.js +2 -1
- package/src/View/Layout/TransposedPopup.d.ts +3 -0
- package/src/View/Layout/TransposedPopup.js +195 -0
- package/src/View/Layout/Wizard/LayoutWizard.js +36 -3
- package/src/View/Layout/Wizard/sections/ColumnsSection.js +1 -1
- package/src/View/Layout/Wizard/sections/RowSummarySection.d.ts +9 -0
- package/src/View/Layout/Wizard/sections/RowSummarySection.js +174 -0
- package/src/View/License/LicenseWatermark.js +1 -61
- package/src/View/Note/NotePopup.d.ts +2 -0
- package/src/View/{Notes/NotesPopup.js → Note/NotePopup.js} +17 -17
- package/src/View/SpecialColumnSettingsWizardStep.js +4 -4
- package/src/View/Theme/ThemeSelector.js +3 -3
- package/src/agGrid/ActionColumnRenderer.js +7 -6
- package/src/agGrid/Adaptable.d.ts +3 -455
- package/src/agGrid/Adaptable.js +8 -5292
- package/src/agGrid/AdaptableAgGrid.d.ts +354 -0
- package/src/agGrid/AdaptableAgGrid.js +3967 -0
- package/src/agGrid/AdaptableLogger.js +77 -11
- package/src/agGrid/AgGridAdapter.d.ts +64 -0
- package/src/agGrid/AgGridAdapter.js +585 -0
- package/src/agGrid/AgGridColumnAdapter.d.ts +56 -0
- package/src/agGrid/AgGridColumnAdapter.js +831 -0
- package/src/agGrid/AgGridMenuAdapter.d.ts +28 -0
- package/src/agGrid/AgGridMenuAdapter.js +277 -0
- package/src/agGrid/AgGridOptionsService.d.ts +15 -0
- package/src/agGrid/AgGridOptionsService.js +76 -0
- package/src/agGrid/BadgeRenderer.js +1 -1
- package/src/agGrid/CheckboxRenderer.js +1 -1
- package/src/agGrid/FilterWrapper.d.ts +2 -2
- package/src/agGrid/FilterWrapper.js +1 -1
- package/src/agGrid/attachAddaptableColumnTypes.d.ts +12 -12
- package/src/agGrid/defaultAdaptableOptions.d.ts +3 -0
- package/src/{Utilities/Defaults/DefaultAdaptableOptions.js → agGrid/defaultAdaptableOptions.js} +71 -17
- package/src/agGrid/editors/AdaptableDateEditor/index.d.ts +1 -1
- package/src/agGrid/editors/AdaptableDateEditor/index.js +3 -3
- package/src/agGrid/editors/AdaptableNumberEditor/index.d.ts +2 -2
- package/src/agGrid/editors/AdaptableNumberEditor/index.js +2 -2
- package/src/agGrid/weightedAverage.d.ts +0 -2
- package/src/agGrid/weightedAverage.js +0 -54
- package/src/components/ColorPicker/ColorPicker.d.ts +1 -1
- package/src/components/Datepicker/index.d.ts +1 -1
- package/src/components/Datepicker/index.js +10 -2
- package/src/components/ExpressionEditor/QueryBuilder/QueryPredicateBuilder.js +2 -1
- package/src/components/ExpressionEditor/QueryBuilder/utils.d.ts +0 -1
- package/src/components/ExpressionEditor/QueryBuilder/utils.js +1 -14
- package/src/components/InfiniteTable/index.js +2 -2
- package/src/components/Input/index.d.ts +1 -2
- package/src/components/List/ListGroupItem/index.d.ts +1 -1
- package/src/components/Modal/index.d.ts +1 -0
- package/src/components/Modal/index.js +4 -3
- package/src/components/Select/Select.d.ts +3 -1
- package/src/components/Select/Select.js +4 -2
- package/src/components/Textarea/index.d.ts +2 -2
- package/src/components/icons/index.js +2 -0
- package/src/components/icons/note.js +2 -2
- package/src/components/icons/rows.d.ts +3 -0
- package/src/components/icons/rows.js +4 -0
- package/src/env.js +2 -2
- package/src/metamodel/adaptable.metamodel.d.ts +179 -25
- package/src/metamodel/adaptable.metamodel.js +1 -9313
- package/src/migration/AdaptableUpgradeHelper.d.ts +38 -0
- package/src/migration/AdaptableUpgradeHelper.js +48 -0
- package/src/migration/VersionUpgrade.d.ts +8 -0
- package/src/migration/VersionUpgrade.js +11 -0
- package/src/migration/VersionUpgrade17.d.ts +18 -0
- package/src/migration/VersionUpgrade17.js +342 -0
- package/src/migration/VersionUpgrade18.d.ts +5 -0
- package/src/migration/VersionUpgrade18.js +6 -0
- package/src/parser/src/parser.js +117 -1257
- package/src/parser/src/predicate/mapExpressionToQlPredicate.js +1 -1
- package/src/parser/src/predicate/mapQlPredicateToExpression.js +2 -1
- package/src/parser/src/types.d.ts +7 -2
- package/src/types.d.ts +26 -19
- package/tsconfig.esm.tsbuildinfo +1 -1
- package/src/AdaptableOptions/CommentsOptions.d.ts +0 -28
- package/src/Api/Events/CommentsChangedInfo.d.ts +0 -5
- package/src/Api/Implementation/NotesApiImpl.d.ts +0 -16
- package/src/Api/Implementation/NotesApiImpl.js +0 -39
- package/src/Api/NotesApi.d.ts +0 -48
- package/src/PredefinedConfig/CellAddress.d.ts +0 -13
- package/src/PredefinedConfig/CellAddress.js +0 -4
- package/src/Redux/ActionsReducers/NotesRedux.d.ts +0 -39
- package/src/Strategy/NotesModule.js +0 -57
- package/src/Utilities/Defaults/DefaultAdaptableOptions.d.ts +0 -2
- package/src/Utilities/Services/Interface/IRowEditService.d.ts +0 -3
- package/src/View/Components/ScopeComponent.d.ts +0 -24
- package/src/View/Components/ScopeComponent.js +0 -133
- package/src/View/Export/Wizard/ReportScopeWizard.d.ts +0 -17
- package/src/View/Export/Wizard/ReportScopeWizard.js +0 -47
- package/src/View/Notes/NotesPopup.d.ts +0 -2
- package/src/agGrid/agGridHelper.d.ts +0 -57
- package/src/agGrid/agGridHelper.js +0 -686
- package/src/agGrid/agGridMenuHelper.d.ts +0 -46
- package/src/agGrid/agGridMenuHelper.js +0 -668
- /package/src/AdaptableOptions/{CommentsOptions.js → CommentOptions.js} +0 -0
- /package/src/AdaptableOptions/{NotesOptions.js → NoteOptions.js} +0 -0
- /package/src/Api/Events/{CommentsChangedInfo.js → CommentChanged.js} +0 -0
- /package/src/Api/{NotesApi.js → NoteApi.js} +0 -0
- /package/src/PredefinedConfig/{NotesState.js → Common/TransposeConfig.js} +0 -0
- /package/src/{Utilities/Services/Interface/IRowEditService.js → PredefinedConfig/NoteState.js} +0 -0
- /package/src/View/{Notes → Note}/NoteEditor.d.ts +0 -0
- /package/src/View/{Notes → Note}/NoteEditor.js +0 -0
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import { ApiBase } from '../Implementation/ApiBase';
|
|
2
|
+
import { AB_SPECIAL_COLUMN, ADAPTABLE_ROW_ACTION_BUTTONS, } from '../../Utilities/Constants/GeneralConstants';
|
|
3
|
+
import UIHelper from '../../View/UIHelper';
|
|
4
|
+
import { ActionColumnRenderer, ReactActionColumnRenderer } from '../../agGrid/ActionColumnRenderer';
|
|
2
5
|
export class ActionRowInternalApi extends ApiBase {
|
|
3
6
|
buildRowEditForm(rowNode) {
|
|
4
7
|
return this.buildActionRow('rowEdited', rowNode);
|
|
@@ -97,7 +100,7 @@ export class ActionRowInternalApi extends ApiBase {
|
|
|
97
100
|
const eventInfo = type === 'rowCreated'
|
|
98
101
|
? {
|
|
99
102
|
type: 'rowCreated',
|
|
100
|
-
formData:
|
|
103
|
+
formData: this.prepareCreateData(formFields, context),
|
|
101
104
|
adaptableApi: context.adaptableApi,
|
|
102
105
|
userName: this.getOptions().userName,
|
|
103
106
|
adaptableId: this.getOptions().adaptableId,
|
|
@@ -117,6 +120,17 @@ export class ActionRowInternalApi extends ApiBase {
|
|
|
117
120
|
};
|
|
118
121
|
return [cancelButton, saveButton];
|
|
119
122
|
}
|
|
123
|
+
// private getNullValueForColumn(column: AdaptableColumn) {}
|
|
124
|
+
prepareCreateData(formFields, context) {
|
|
125
|
+
// when creating we just omit values that are not set
|
|
126
|
+
const dataToSave = Object.assign({}, context.formData);
|
|
127
|
+
for (const formField of formFields) {
|
|
128
|
+
if (dataToSave[formField.name] === '') {
|
|
129
|
+
delete dataToSave[formField.name];
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
return dataToSave;
|
|
133
|
+
}
|
|
120
134
|
prepareEditData(formFields, context) {
|
|
121
135
|
const dataToSave = Object.assign({}, context.formData);
|
|
122
136
|
for (const formField of formFields) {
|
|
@@ -197,4 +211,107 @@ export class ActionRowInternalApi extends ApiBase {
|
|
|
197
211
|
label: value,
|
|
198
212
|
}));
|
|
199
213
|
}
|
|
214
|
+
getColDefsForActionRowColumns() {
|
|
215
|
+
const actionButtons = this.getActionRowButtonDefs();
|
|
216
|
+
if (!actionButtons.length) {
|
|
217
|
+
return [];
|
|
218
|
+
}
|
|
219
|
+
return [
|
|
220
|
+
{
|
|
221
|
+
headerName: '',
|
|
222
|
+
colId: ADAPTABLE_ROW_ACTION_BUTTONS,
|
|
223
|
+
hide: false,
|
|
224
|
+
editable: false,
|
|
225
|
+
// 15px is the icon width + left&right padding + left&right border
|
|
226
|
+
width: Math.max(actionButtons.length * (UIHelper.getSimpleButtonPaddingWidth() * 2 + 15) + 2,
|
|
227
|
+
// If the width of the column is to small, the width will not be applied
|
|
228
|
+
// this triggers the setLayout an infinite loop because the width read from the grid is always different
|
|
229
|
+
40),
|
|
230
|
+
resizable: false,
|
|
231
|
+
lockVisible: true,
|
|
232
|
+
suppressColumnsToolPanel: true,
|
|
233
|
+
suppressFiltersToolPanel: true,
|
|
234
|
+
suppressHeaderMenuButton: true,
|
|
235
|
+
suppressMovable: true,
|
|
236
|
+
filter: false,
|
|
237
|
+
sortable: false,
|
|
238
|
+
enableRowGroup: false,
|
|
239
|
+
pinned: this.getActionRowOptions().actionRowButtonOptions.position === 'pinnedRight'
|
|
240
|
+
? 'right'
|
|
241
|
+
: 'left',
|
|
242
|
+
cellRenderer: this.getAdaptableVariant() === 'react' ? ReactActionColumnRenderer : ActionColumnRenderer,
|
|
243
|
+
cellClass: ADAPTABLE_ROW_ACTION_BUTTONS,
|
|
244
|
+
type: [AB_SPECIAL_COLUMN, 'abColDefObject'],
|
|
245
|
+
},
|
|
246
|
+
];
|
|
247
|
+
}
|
|
248
|
+
getActionRowButtonDefs() {
|
|
249
|
+
const actionRowButtons = this.getActionRowApi().getActionRowButtons();
|
|
250
|
+
if (!(actionRowButtons === null || actionRowButtons === void 0 ? void 0 : actionRowButtons.length)) {
|
|
251
|
+
return [];
|
|
252
|
+
}
|
|
253
|
+
const defaultActionRowButtonConfiguration = {
|
|
254
|
+
create: {
|
|
255
|
+
icon: {
|
|
256
|
+
name: 'add',
|
|
257
|
+
},
|
|
258
|
+
tooltip: 'Create',
|
|
259
|
+
onClick: () => {
|
|
260
|
+
this.getActionRowApi().displayCreateActionRow();
|
|
261
|
+
},
|
|
262
|
+
},
|
|
263
|
+
edit: {
|
|
264
|
+
icon: {
|
|
265
|
+
name: 'edit',
|
|
266
|
+
},
|
|
267
|
+
tooltip: 'Edit',
|
|
268
|
+
onClick: (button, context) => {
|
|
269
|
+
this.getActionRowApi().displayEditActionRow(context.primaryKeyValue);
|
|
270
|
+
},
|
|
271
|
+
},
|
|
272
|
+
clone: {
|
|
273
|
+
icon: {
|
|
274
|
+
name: 'clone',
|
|
275
|
+
},
|
|
276
|
+
tooltip: 'Clone',
|
|
277
|
+
onClick: (button, context) => {
|
|
278
|
+
this.getActionRowApi().displayCloneActionRow(context.primaryKeyValue);
|
|
279
|
+
},
|
|
280
|
+
},
|
|
281
|
+
delete: {
|
|
282
|
+
icon: {
|
|
283
|
+
name: 'delete',
|
|
284
|
+
},
|
|
285
|
+
tooltip: 'Delete',
|
|
286
|
+
onClick: (button, context) => {
|
|
287
|
+
var _a, _b;
|
|
288
|
+
const eventInfo = {
|
|
289
|
+
type: 'rowDeleted',
|
|
290
|
+
rowNode: context.rowNode,
|
|
291
|
+
adaptableApi: context.adaptableApi,
|
|
292
|
+
userName: context.userName,
|
|
293
|
+
adaptableId: context.adaptableId,
|
|
294
|
+
};
|
|
295
|
+
this.getEventApi().emit('ActionRowSubmitted', eventInfo);
|
|
296
|
+
(_b = (_a = this.getActionRowOptions().actionRowFormOptions).onFormSubmit) === null || _b === void 0 ? void 0 : _b.call(_a, eventInfo);
|
|
297
|
+
},
|
|
298
|
+
},
|
|
299
|
+
};
|
|
300
|
+
const actionButtons = actionRowButtons
|
|
301
|
+
.map((actionRowButtonType) => {
|
|
302
|
+
var _a, _b;
|
|
303
|
+
const defaultButtonConfig = defaultActionRowButtonConfiguration[actionRowButtonType];
|
|
304
|
+
if (!defaultButtonConfig) {
|
|
305
|
+
// should NOT happen unless the user sent some invalid button type in the predefined config
|
|
306
|
+
return;
|
|
307
|
+
}
|
|
308
|
+
const customButtonConfig = (_b = (_a = this.getActionRowOptions().actionRowButtonOptions).customConfiguration) === null || _b === void 0 ? void 0 : _b.call(_a, Object.assign(Object.assign({}, this.getAdaptableApi().internalApi.buildBaseContext()), { actionRowButtonType }));
|
|
309
|
+
if (!customButtonConfig) {
|
|
310
|
+
return defaultButtonConfig;
|
|
311
|
+
}
|
|
312
|
+
return Object.assign(Object.assign({}, defaultButtonConfig), customButtonConfig);
|
|
313
|
+
})
|
|
314
|
+
.filter(Boolean);
|
|
315
|
+
return actionButtons;
|
|
316
|
+
}
|
|
200
317
|
}
|
|
@@ -24,9 +24,9 @@ import { AdaptableFrameworkComponent } from '../../AdaptableOptions/AdaptableFra
|
|
|
24
24
|
import { IMetamodelService } from '../../Utilities/Services/Interface/IMetamodelService';
|
|
25
25
|
import { IModuleCollection } from '../../Strategy/Interface/IModule';
|
|
26
26
|
import { AdaptableObjectTag, AdaptableObjectWithScope } from '../../PredefinedConfig/Common/AdaptableObject';
|
|
27
|
-
import { IRowEditService } from '../../Utilities/Services/Interface/IRowEditService';
|
|
28
27
|
import { Fdc3Service } from '../../Utilities/Services/Fdc3Service';
|
|
29
28
|
import { CellPopupService } from '../../Utilities/Services/CellPopupService';
|
|
29
|
+
import { RowEditService } from '../../Utilities/Services/RowEditService';
|
|
30
30
|
export declare class AdaptableInternalApi extends ApiBase {
|
|
31
31
|
getSystemState(): SystemState;
|
|
32
32
|
showPopupConfirmation(confirmation: UIConfirmation): void;
|
|
@@ -46,8 +46,7 @@ export declare class AdaptableInternalApi extends ApiBase {
|
|
|
46
46
|
setPivotModeOn(): void;
|
|
47
47
|
setPivotModeOff(): void;
|
|
48
48
|
isGridInPivotMode(): boolean;
|
|
49
|
-
|
|
50
|
-
setTreeModeOff(): void;
|
|
49
|
+
setTreeMode(mode: boolean): void;
|
|
51
50
|
isGridInTreeMode(): boolean;
|
|
52
51
|
getToolbarTitle(): string;
|
|
53
52
|
buildDataChangedInfo(config: Pick<CellDataChangedInfo, 'newValue' | 'oldValue' | 'column' | 'primaryKeyValue' | 'rowNode' | 'trigger'>): CellDataChangedInfo;
|
|
@@ -65,7 +64,7 @@ export declare class AdaptableInternalApi extends ApiBase {
|
|
|
65
64
|
getAlertService(): IAlertService;
|
|
66
65
|
getTeamSharingService(): ITeamSharingService;
|
|
67
66
|
getMetamodelService(): IMetamodelService;
|
|
68
|
-
getRowEditService():
|
|
67
|
+
getRowEditService(): RowEditService;
|
|
69
68
|
getFdc3Service(): Fdc3Service;
|
|
70
69
|
getModules(): IModuleCollection;
|
|
71
70
|
getModuleFriendlyName(adaptableModule: AdaptableModule): string;
|
|
@@ -73,7 +72,7 @@ export declare class AdaptableInternalApi extends ApiBase {
|
|
|
73
72
|
includeGroupRows?: boolean;
|
|
74
73
|
filterFn?: (rowNode: IRowNode) => boolean;
|
|
75
74
|
}): void;
|
|
76
|
-
forAllVisibleRowNodesDo(func: (rowNode: IRowNode) => void, config?: {
|
|
75
|
+
forAllVisibleRowNodesDo(func: (rowNode: IRowNode, index: number) => void, config?: {
|
|
77
76
|
includeGroupRows?: boolean;
|
|
78
77
|
filterFn?: (rowNode: IRowNode) => boolean;
|
|
79
78
|
}): void;
|
|
@@ -106,8 +105,8 @@ export declare class AdaptableInternalApi extends ApiBase {
|
|
|
106
105
|
getPreviousGroupedColumnsIndex(layoutId: string): {
|
|
107
106
|
[key: string]: number;
|
|
108
107
|
};
|
|
109
|
-
getValueUsingField(rowData: Record<string, any>,
|
|
110
|
-
setValueUsingField(rowData: Record<string, any>,
|
|
108
|
+
getValueUsingField(rowData: Record<string, any>, fieldName: string): any;
|
|
109
|
+
setValueUsingField(rowData: Record<string, any>, fieldName: string, newValue: any): Record<string, any>;
|
|
111
110
|
findAdaptableObjectsByLookupCriteria<T extends AdaptableObjectWithScope>({ scope, tag, ids }: AdaptableObjectLookupCriteria, specificAdaptableObjects: T[]): T[];
|
|
112
111
|
buildBaseContext(): BaseContext;
|
|
113
112
|
getActionButtonsAndActionColumn(colDef: ColDef): {
|
|
@@ -47,11 +47,13 @@ export class AdaptableInternalApi extends ApiBase {
|
|
|
47
47
|
isGridInPivotMode() {
|
|
48
48
|
return this.getAdaptableState().Grid.IsGridInPivotMode;
|
|
49
49
|
}
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
50
|
+
setTreeMode(mode) {
|
|
51
|
+
if (!!mode) {
|
|
52
|
+
this.dispatchAction(GridRedux.SetTreeModeOn());
|
|
53
|
+
}
|
|
54
|
+
else {
|
|
55
|
+
this.dispatchAction(GridRedux.SetTreeModeOff());
|
|
56
|
+
}
|
|
55
57
|
}
|
|
56
58
|
isGridInTreeMode() {
|
|
57
59
|
return this.getAdaptableState().Grid.IsGridInTreeMode;
|
|
@@ -219,13 +221,13 @@ export class AdaptableInternalApi extends ApiBase {
|
|
|
219
221
|
frameworkComponent,
|
|
220
222
|
componentType,
|
|
221
223
|
});
|
|
222
|
-
if (this.adaptable.
|
|
224
|
+
if (this.adaptable.isReady) {
|
|
223
225
|
createComponentFn();
|
|
224
226
|
}
|
|
225
227
|
else {
|
|
226
228
|
// adaptable may not be initialized yet if the framework component is part of the initial render
|
|
227
229
|
// AFL 2021.10.14 - not really sure if this is necessary anymore?! (see the other changes in this commit)
|
|
228
|
-
waitForCondition(() => this.adaptable.
|
|
230
|
+
waitForCondition(() => this.adaptable.isReady).then(() => {
|
|
229
231
|
createComponentFn();
|
|
230
232
|
});
|
|
231
233
|
}
|
|
@@ -364,17 +366,17 @@ export class AdaptableInternalApi extends ApiBase {
|
|
|
364
366
|
return (_a = SystemRedux.SystemPreviousGroupedColumnsSelector(this.getAdaptableState().System)) === null || _a === void 0 ? void 0 : _a[layoutId];
|
|
365
367
|
}
|
|
366
368
|
// "borrowed" from https://github.com/ag-grid/ag-grid/blob/v28.2.1/community-modules/core/src/ts/utils/object.ts#L205
|
|
367
|
-
getValueUsingField(rowData,
|
|
368
|
-
if (!rowData || !(
|
|
369
|
+
getValueUsingField(rowData, fieldName) {
|
|
370
|
+
if (!rowData || !(fieldName === null || fieldName === void 0 ? void 0 : fieldName.length)) {
|
|
369
371
|
return;
|
|
370
372
|
}
|
|
371
|
-
const isColumnValueKeyNested =
|
|
373
|
+
const isColumnValueKeyNested = fieldName === null || fieldName === void 0 ? void 0 : fieldName.includes('.');
|
|
372
374
|
// if no '.', then it's not a deep value
|
|
373
375
|
if (!isColumnValueKeyNested) {
|
|
374
|
-
return rowData[
|
|
376
|
+
return rowData[fieldName];
|
|
375
377
|
}
|
|
376
378
|
// otherwise it is a deep value, so need to dig for it
|
|
377
|
-
const fields =
|
|
379
|
+
const fields = fieldName.split('.');
|
|
378
380
|
let currentObject = rowData;
|
|
379
381
|
for (let i = 0; i < fields.length; i++) {
|
|
380
382
|
if (currentObject == null) {
|
|
@@ -385,22 +387,22 @@ export class AdaptableInternalApi extends ApiBase {
|
|
|
385
387
|
return currentObject;
|
|
386
388
|
}
|
|
387
389
|
// "borrowed" from https://github.com/ag-grid/ag-grid/blob/v28.2.1/community-modules/core/src/ts/valueService/valueService.ts#L236
|
|
388
|
-
setValueUsingField(rowData,
|
|
389
|
-
if (!rowData || !(
|
|
390
|
+
setValueUsingField(rowData, fieldName, newValue) {
|
|
391
|
+
if (!rowData || !(fieldName === null || fieldName === void 0 ? void 0 : fieldName.length)) {
|
|
390
392
|
return;
|
|
391
393
|
}
|
|
392
|
-
const isColumnValueKeyContainsDots =
|
|
394
|
+
const isColumnValueKeyContainsDots = fieldName === null || fieldName === void 0 ? void 0 : fieldName.includes('.');
|
|
393
395
|
let valuesAreSame = false;
|
|
394
396
|
if (!isColumnValueKeyContainsDots) {
|
|
395
397
|
// soft comparison to match strings and numbers
|
|
396
|
-
valuesAreSame = rowData[
|
|
398
|
+
valuesAreSame = rowData[fieldName] == newValue;
|
|
397
399
|
if (!valuesAreSame) {
|
|
398
|
-
rowData[
|
|
400
|
+
rowData[fieldName] = newValue;
|
|
399
401
|
}
|
|
400
402
|
}
|
|
401
403
|
else {
|
|
402
404
|
// otherwise it is a deep value, so need to dig for it
|
|
403
|
-
const fieldPieces =
|
|
405
|
+
const fieldPieces = fieldName.split('.');
|
|
404
406
|
let currentObject = rowData;
|
|
405
407
|
while (fieldPieces.length > 0 && currentObject) {
|
|
406
408
|
const fieldPiece = fieldPieces.shift();
|
|
@@ -448,7 +450,7 @@ export class AdaptableInternalApi extends ApiBase {
|
|
|
448
450
|
var _a;
|
|
449
451
|
let actionColumn;
|
|
450
452
|
if (colDef.colId == ADAPTABLE_ROW_ACTION_BUTTONS) {
|
|
451
|
-
const actionButtons = this.
|
|
453
|
+
const actionButtons = this.getActionRowApi().internalApi.getActionRowButtonDefs();
|
|
452
454
|
actionColumn = {
|
|
453
455
|
columnId: ADAPTABLE_ROW_ACTION_BUTTONS,
|
|
454
456
|
actionColumnButton: actionButtons,
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ApiBase } from '../Implementation/ApiBase';
|
|
2
2
|
import { CalculatedColumn } from '../../PredefinedConfig/CalculatedColumnState';
|
|
3
3
|
import { AdaptableColumn } from '../../types';
|
|
4
|
+
import { ColDef } from '@ag-grid-community/core';
|
|
4
5
|
export declare class CalculatedColumnInternalApi extends ApiBase {
|
|
5
6
|
/**
|
|
6
7
|
* Returns all the references in the AdaptableState of the given CalculatedColumn
|
|
@@ -27,4 +28,5 @@ export declare class CalculatedColumnInternalApi extends ApiBase {
|
|
|
27
28
|
isQuantileAggregatedExpression(input: string): boolean;
|
|
28
29
|
getExpressionFromCalculatedColumn(calculatedColumn: CalculatedColumn): string;
|
|
29
30
|
fireCalculatedColumnChangedEvent(trigger: string, calculatedColumn: CalculatedColumn): void;
|
|
31
|
+
getColDefsForCalculatedColumns(): ColDef[];
|
|
30
32
|
}
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import { ApiBase } from '../Implementation/ApiBase';
|
|
2
|
+
import { CreateEmptyCalculatedColumn } from '../../Utilities/ObjectFactory';
|
|
3
|
+
import { AB_SPECIAL_COLUMN } from '../../Utilities/Constants/GeneralConstants';
|
|
4
|
+
import ArrayExtensions from '../../Utilities/Extensions/ArrayExtensions';
|
|
5
|
+
import StringExtensions from '../../Utilities/Extensions/StringExtensions';
|
|
2
6
|
export class CalculatedColumnInternalApi extends ApiBase {
|
|
3
7
|
/**
|
|
4
8
|
* Returns all the references in the AdaptableState of the given CalculatedColumn
|
|
@@ -87,4 +91,71 @@ export class CalculatedColumnInternalApi extends ApiBase {
|
|
|
87
91
|
};
|
|
88
92
|
this.adaptable.api.eventApi.emit('CalculatedColumnChanged', calculatedColumnChangedInfo);
|
|
89
93
|
}
|
|
94
|
+
getColDefsForCalculatedColumns() {
|
|
95
|
+
const defaultSpecialColumnSettings = this.getGridApi().internalApi.deriveSpecialColumnSettingsFromAgGridDefaultColDef();
|
|
96
|
+
const defaultCalculatedColumnSettings = CreateEmptyCalculatedColumn(defaultSpecialColumnSettings).CalculatedColumnSettings;
|
|
97
|
+
return this.getCalculatedColumnApi()
|
|
98
|
+
.getCalculatedColumns()
|
|
99
|
+
.map((calculatedColumn) => {
|
|
100
|
+
const calculatedColumnSettings = Object.assign(Object.assign({}, defaultCalculatedColumnSettings), calculatedColumn.CalculatedColumnSettings);
|
|
101
|
+
if (!calculatedColumnSettings.DataType) {
|
|
102
|
+
calculatedColumnSettings.DataType = this.getAdaptableApi()
|
|
103
|
+
.internalApi.getAdaptableInstance()
|
|
104
|
+
.CalculatedColumnExpressionService.getCalculatedColumnDataType(calculatedColumn.Query);
|
|
105
|
+
}
|
|
106
|
+
const columnTypes = [
|
|
107
|
+
AB_SPECIAL_COLUMN,
|
|
108
|
+
this.getGridApi().internalApi.getAgGridDataType(calculatedColumnSettings.DataType),
|
|
109
|
+
];
|
|
110
|
+
if (ArrayExtensions.IsNotNullOrEmpty(calculatedColumnSettings.ColumnTypes)) {
|
|
111
|
+
columnTypes.push(...calculatedColumnSettings.ColumnTypes);
|
|
112
|
+
}
|
|
113
|
+
const isExternalEvaluation = !this.getExpressionApi().internalApi.evaluateExpressionInAdaptableQL('CalculatedColumn', calculatedColumn, this.getExpressionApi().getAdaptableQueryExpression(calculatedColumn.Query));
|
|
114
|
+
const valueGetter = (params) => {
|
|
115
|
+
var _a, _b;
|
|
116
|
+
if (isExternalEvaluation) {
|
|
117
|
+
return (_a = params.data) === null || _a === void 0 ? void 0 : _a[calculatedColumn.ColumnId];
|
|
118
|
+
}
|
|
119
|
+
// if the grid data is NOT client side, we can aggregate only simple scalar expression (which depend on row data, not on other rows)
|
|
120
|
+
if (this.getGridApi().getAgGridRowModelType() !== 'clientSide' &&
|
|
121
|
+
StringExtensions.IsNotNullOrEmpty(calculatedColumn.Query.AggregatedScalarExpression)) {
|
|
122
|
+
return (_b = params.data) === null || _b === void 0 ? void 0 : _b[calculatedColumn.ColumnId];
|
|
123
|
+
}
|
|
124
|
+
return this.getAdaptableApi()
|
|
125
|
+
.internalApi.getAdaptableInstance()
|
|
126
|
+
.CalculatedColumnExpressionService.evaluateCalculatedColumnQuery(calculatedColumn, params.node);
|
|
127
|
+
};
|
|
128
|
+
const newColDef = {
|
|
129
|
+
headerName: calculatedColumn.FriendlyName
|
|
130
|
+
? calculatedColumn.FriendlyName
|
|
131
|
+
: calculatedColumn.ColumnId,
|
|
132
|
+
colId: calculatedColumn.ColumnId,
|
|
133
|
+
hide: false,
|
|
134
|
+
editable: false,
|
|
135
|
+
width: calculatedColumnSettings.Width,
|
|
136
|
+
enableValue: calculatedColumnSettings.Aggregatable,
|
|
137
|
+
filter: calculatedColumnSettings.Filterable,
|
|
138
|
+
floatingFilter: calculatedColumnSettings.Filterable,
|
|
139
|
+
resizable: calculatedColumnSettings.Resizable,
|
|
140
|
+
enableRowGroup: calculatedColumnSettings.Groupable,
|
|
141
|
+
sortable: calculatedColumnSettings.Sortable,
|
|
142
|
+
enablePivot: calculatedColumnSettings.Pivotable,
|
|
143
|
+
suppressHeaderMenuButton: calculatedColumnSettings.SuppressMenu,
|
|
144
|
+
suppressMovable: calculatedColumnSettings.SuppressMovable,
|
|
145
|
+
type: columnTypes,
|
|
146
|
+
valueGetter,
|
|
147
|
+
};
|
|
148
|
+
if (calculatedColumnSettings.ShowToolTip != null &&
|
|
149
|
+
calculatedColumnSettings.ShowToolTip == true) {
|
|
150
|
+
newColDef.tooltipValueGetter = () => {
|
|
151
|
+
return this.getAdaptableApi().internalApi.getAdaptableQueryExpressionText(calculatedColumn.Query);
|
|
152
|
+
};
|
|
153
|
+
}
|
|
154
|
+
if (calculatedColumnSettings.HeaderToolTip) {
|
|
155
|
+
newColDef.headerTooltip = calculatedColumnSettings.HeaderToolTip;
|
|
156
|
+
}
|
|
157
|
+
this.getAdaptableApi().logInfo('Setting up Calculated Column: ' + calculatedColumn.ColumnId);
|
|
158
|
+
return newColDef;
|
|
159
|
+
});
|
|
160
|
+
}
|
|
90
161
|
}
|
|
@@ -49,6 +49,7 @@ export declare class ColumnFilterInternalApi extends ApiBase {
|
|
|
49
49
|
* Fires Column Filter Applied Event - typically used to enable filtering on the server
|
|
50
50
|
*/
|
|
51
51
|
fireColumnFilterAppliedEvent(): void;
|
|
52
|
+
fireGridFilterAppliedEvent(): void;
|
|
52
53
|
/**
|
|
53
54
|
* Compares to sets of Column Filters to see if they are identical
|
|
54
55
|
* @param filters1
|
|
@@ -56,4 +57,5 @@ export declare class ColumnFilterInternalApi extends ApiBase {
|
|
|
56
57
|
*/
|
|
57
58
|
areColumnFiltersDifferent(oldFilters: ColumnFilter[], newFilters: ColumnFilter[]): boolean;
|
|
58
59
|
getPredicateDefShortcuts(predicateDef: AdaptablePredicateDef): string[];
|
|
60
|
+
getFilterValuesMaxNumberOfItems(column: AdaptableColumn): number | undefined;
|
|
59
61
|
}
|
|
@@ -171,7 +171,7 @@ export class ColumnFilterInternalApi extends ApiBase {
|
|
|
171
171
|
* Fires Column Filter Applied Event - typically used to enable filtering on the server
|
|
172
172
|
*/
|
|
173
173
|
fireColumnFilterAppliedEvent() {
|
|
174
|
-
if (this.adaptable.
|
|
174
|
+
if (this.adaptable.isReady) {
|
|
175
175
|
const adaptableApi = this.getAdaptableApi();
|
|
176
176
|
const columnFilterAppliedInfo = {
|
|
177
177
|
columnFilters: this.getColumnFilterApi().getColumnFilters(),
|
|
@@ -182,6 +182,18 @@ export class ColumnFilterInternalApi extends ApiBase {
|
|
|
182
182
|
this.adaptable.api.eventApi.emit('ColumnFilterApplied', columnFilterAppliedInfo);
|
|
183
183
|
}
|
|
184
184
|
}
|
|
185
|
+
fireGridFilterAppliedEvent() {
|
|
186
|
+
if (this.adaptable.isReady) {
|
|
187
|
+
const adaptableApi = this.getAdaptableApi();
|
|
188
|
+
const gridFilterAppliedInfo = {
|
|
189
|
+
columnFilters: this.getColumnFilterApi().getColumnFilters(),
|
|
190
|
+
adaptableApi: adaptableApi,
|
|
191
|
+
userName: adaptableApi.optionsApi.getUserName(),
|
|
192
|
+
adaptableId: adaptableApi.optionsApi.getAdaptableId(),
|
|
193
|
+
};
|
|
194
|
+
this.adaptable.api.eventApi.emit('GridFilterApplied', gridFilterAppliedInfo);
|
|
195
|
+
}
|
|
196
|
+
}
|
|
185
197
|
/**
|
|
186
198
|
* Compares to sets of Column Filters to see if they are identical
|
|
187
199
|
* @param filters1
|
|
@@ -202,4 +214,14 @@ export class ColumnFilterInternalApi extends ApiBase {
|
|
|
202
214
|
}
|
|
203
215
|
return predicateShortcuts;
|
|
204
216
|
}
|
|
217
|
+
getFilterValuesMaxNumberOfItems(column) {
|
|
218
|
+
const maxFilterValues = this.getColumnFilterOptions().valuesFilterOptions.maxFilterValuesToDisplay;
|
|
219
|
+
if (typeof maxFilterValues === 'function') {
|
|
220
|
+
const columnFilterContext = Object.assign(Object.assign({}, this.getAdaptableApi().internalApi.buildBaseContext()), { column: column });
|
|
221
|
+
return maxFilterValues(columnFilterContext);
|
|
222
|
+
}
|
|
223
|
+
else {
|
|
224
|
+
return maxFilterValues;
|
|
225
|
+
}
|
|
226
|
+
}
|
|
205
227
|
}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { ApiBase } from '../Implementation/ApiBase';
|
|
2
|
-
import { Column } from '@ag-grid-community/core';
|
|
2
|
+
import { Column, IRowNode } from '@ag-grid-community/core';
|
|
3
|
+
import { CustomSort } from '../../PredefinedConfig/CustomSortState';
|
|
4
|
+
import { ColumnValuesComparer } from '../../AdaptableOptions/CustomSortOptions';
|
|
3
5
|
export declare class ColumnInternalApi extends ApiBase {
|
|
4
6
|
/**
|
|
5
7
|
* Retrieves 'ColumnType' property for a given Column
|
|
@@ -24,4 +26,5 @@ export declare class ColumnInternalApi extends ApiBase {
|
|
|
24
26
|
*/
|
|
25
27
|
getAgGridColumnForAdaptableColumn(columnId: string): Column;
|
|
26
28
|
isActionRowButtonColumn(columnId: string): boolean;
|
|
29
|
+
getActiveColumnComparator(columnId: string, customSort?: CustomSort, customSortComparer?: ColumnValuesComparer): (valueA: any, valueB: any, nodeA?: IRowNode, nodeB?: IRowNode, isInverted?: boolean) => number | undefined;
|
|
27
30
|
}
|
|
@@ -39,4 +39,16 @@ export class ColumnInternalApi extends ApiBase {
|
|
|
39
39
|
isActionRowButtonColumn(columnId) {
|
|
40
40
|
return columnId === ADAPTABLE_ROW_ACTION_BUTTONS;
|
|
41
41
|
}
|
|
42
|
+
getActiveColumnComparator(columnId, customSort, customSortComparer) {
|
|
43
|
+
if ((!customSort || (customSort === null || customSort === void 0 ? void 0 : customSort.IsSuspended)) && !customSortComparer) {
|
|
44
|
+
// defaults to AG-Grid column definition comparator if no CustomSort is defined&active
|
|
45
|
+
const colDefComparator = this.adaptable.agGridColumnAdapter.getUserColDefProperty(columnId, 'comparator');
|
|
46
|
+
return colDefComparator;
|
|
47
|
+
}
|
|
48
|
+
// CustomSort Comparer function takes precedence over CustomSort SortedValues
|
|
49
|
+
const comparerFunction = customSortComparer
|
|
50
|
+
? customSortComparer.comparer
|
|
51
|
+
: this.getCustomSortApi().internalApi.getDefaultCustomSortComparer(customSort.ColumnId, customSort.SortedValues);
|
|
52
|
+
return comparerFunction;
|
|
53
|
+
}
|
|
42
54
|
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ApiBase } from '../Implementation/ApiBase';
|
|
2
|
+
export class CommentsInternalApi extends ApiBase {
|
|
3
|
+
areCommentsAvailable() {
|
|
4
|
+
var _a;
|
|
5
|
+
const currentLayout = this.getLayoutApi().getCurrentLayout();
|
|
6
|
+
if (currentLayout.EnablePivot) {
|
|
7
|
+
return false;
|
|
8
|
+
}
|
|
9
|
+
if ((_a = currentLayout === null || currentLayout === void 0 ? void 0 : currentLayout.RowGroupedColumns) === null || _a === void 0 ? void 0 : _a.length) {
|
|
10
|
+
return false;
|
|
11
|
+
}
|
|
12
|
+
return true;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ApiBase } from '../Implementation/ApiBase';
|
|
2
|
-
import { AdaptableColumn } from '../../PredefinedConfig/Common/AdaptableColumn';
|
|
3
2
|
import { ColumnValuesComparer } from '../../AdaptableOptions/CustomSortOptions';
|
|
3
|
+
import { AdaptableComparerFunction } from '../../PredefinedConfig/Common/AdaptableComparerFunction';
|
|
4
4
|
export declare class CustomSortInternalApi extends ApiBase {
|
|
5
|
-
getCustomSortComparer(
|
|
5
|
+
getCustomSortComparer(columnId: string): ColumnValuesComparer | undefined;
|
|
6
|
+
getDefaultCustomSortComparer(columnId: string, columnValues: any[]): AdaptableComparerFunction;
|
|
6
7
|
}
|
|
@@ -1,7 +1,38 @@
|
|
|
1
1
|
import { ApiBase } from '../Implementation/ApiBase';
|
|
2
2
|
export class CustomSortInternalApi extends ApiBase {
|
|
3
|
-
getCustomSortComparer(
|
|
3
|
+
getCustomSortComparer(columnId) {
|
|
4
4
|
var _a;
|
|
5
|
+
const column = this.getColumnApi().getColumnWithColumnId(columnId);
|
|
5
6
|
return (_a = this.getCustomSortOptions().customSortComparers) === null || _a === void 0 ? void 0 : _a.find((csc) => this.adaptable.api.scopeApi.isColumnInScope(column, csc.scope));
|
|
6
7
|
}
|
|
8
|
+
getDefaultCustomSortComparer(columnId, columnValues) {
|
|
9
|
+
// have to return a function that may not have access to this
|
|
10
|
+
const adaptable = this.adaptable;
|
|
11
|
+
return function compareItemsOfCustomSort(valueA, valueB, nodeA, nodeB) {
|
|
12
|
+
var _a, _b;
|
|
13
|
+
let firstElementValueString = (_a = (nodeA && adaptable.getDisplayValueFromRowNode(nodeA, columnId))) !== null && _a !== void 0 ? _a : valueA;
|
|
14
|
+
let secondElementValueString = (_b = (nodeB && adaptable.getDisplayValueFromRowNode(nodeB, columnId))) !== null && _b !== void 0 ? _b : valueB;
|
|
15
|
+
let indexFirstElement = columnValues.indexOf(firstElementValueString);
|
|
16
|
+
let containsFirstElement = indexFirstElement >= 0;
|
|
17
|
+
let indexSecondElement = columnValues.indexOf(secondElementValueString);
|
|
18
|
+
let containsSecondElement = indexSecondElement >= 0;
|
|
19
|
+
//if none of the element are in the list we jsut return normal compare
|
|
20
|
+
if (!containsFirstElement && !containsSecondElement) {
|
|
21
|
+
if (valueA == valueB) {
|
|
22
|
+
return 0;
|
|
23
|
+
}
|
|
24
|
+
return valueA < valueB ? -1 : 1;
|
|
25
|
+
}
|
|
26
|
+
//if first item not in the list make sure we put it after the second item
|
|
27
|
+
if (!containsFirstElement) {
|
|
28
|
+
return 1;
|
|
29
|
+
}
|
|
30
|
+
//if second item not in the list make sure we put it after the first item
|
|
31
|
+
if (!containsSecondElement) {
|
|
32
|
+
return -1;
|
|
33
|
+
}
|
|
34
|
+
//return the comparison from the list if the two items are in the list
|
|
35
|
+
return indexFirstElement - indexSecondElement;
|
|
36
|
+
};
|
|
37
|
+
}
|
|
7
38
|
}
|
|
@@ -5,7 +5,7 @@ export class DataSetInternalApi extends ApiBase {
|
|
|
5
5
|
* @param dataSet Data Set which has been selected
|
|
6
6
|
*/
|
|
7
7
|
fireDataSetSelectedEvent(dataSet) {
|
|
8
|
-
if (this.adaptable.
|
|
8
|
+
if (this.adaptable.isReady) {
|
|
9
9
|
const dataSetSelectedInfo = {
|
|
10
10
|
adaptableApi: this.adaptable.api,
|
|
11
11
|
dataSet,
|
|
@@ -2,7 +2,7 @@ import { ApiBase } from '../Implementation/ApiBase';
|
|
|
2
2
|
import { CellDataChangedInfo } from '../../PredefinedConfig/Common/CellDataChangedInfo';
|
|
3
3
|
import { Report } from '../../PredefinedConfig/ExportState';
|
|
4
4
|
import { AdaptableColumnType } from '../../PredefinedConfig/Common/Types';
|
|
5
|
-
import { ExcelDataType } from '@ag-grid-community/core';
|
|
5
|
+
import { ExcelDataType, ExcelStyle } from '@ag-grid-community/core';
|
|
6
6
|
import { AdaptableColumnDataType } from '../../PredefinedConfig/Common/AdaptableColumn';
|
|
7
7
|
import { DataFormatType } from '../../AdaptableOptions/ExportOptions';
|
|
8
8
|
export declare class ExportInternalApi extends ApiBase {
|
|
@@ -17,4 +17,5 @@ export declare class ExportInternalApi extends ApiBase {
|
|
|
17
17
|
isDateCellExportedAsFormattedValue(): boolean;
|
|
18
18
|
getCellExportFormatType(columnDataType: AdaptableColumnDataType): DataFormatType;
|
|
19
19
|
isDestinationEnabled(destination: string): boolean;
|
|
20
|
+
getExcelStylesForVisualDataExport(original_excelStyles: ExcelStyle[]): ExcelStyle[];
|
|
20
21
|
}
|
|
@@ -92,7 +92,7 @@ export class ExportInternalApi extends ApiBase {
|
|
|
92
92
|
}
|
|
93
93
|
}
|
|
94
94
|
isVisualDataExportInProgress() {
|
|
95
|
-
return this.getAdaptableState().System.Export.
|
|
95
|
+
return this.getAdaptableState().System.Export.visualDataExportInProgress;
|
|
96
96
|
}
|
|
97
97
|
isDateCellExportedAsFormattedValue() {
|
|
98
98
|
return (!!this.getExportOptions().exportDateFormat ||
|
|
@@ -123,4 +123,7 @@ export class ExportInternalApi extends ApiBase {
|
|
|
123
123
|
}
|
|
124
124
|
return true;
|
|
125
125
|
}
|
|
126
|
+
getExcelStylesForVisualDataExport(original_excelStyles) {
|
|
127
|
+
return [];
|
|
128
|
+
}
|
|
126
129
|
}
|
|
@@ -39,7 +39,7 @@ export class Fdc3InternalApi extends ApiBase {
|
|
|
39
39
|
editable: false,
|
|
40
40
|
width: actionColumnConfig.width,
|
|
41
41
|
resizable: actionColumnConfig.resizable,
|
|
42
|
-
|
|
42
|
+
suppressHeaderMenuButton: true,
|
|
43
43
|
suppressMovable: !actionColumnConfig.movable,
|
|
44
44
|
filter: false,
|
|
45
45
|
sortable: false,
|
|
@@ -59,7 +59,7 @@ export class Fdc3InternalApi extends ApiBase {
|
|
|
59
59
|
editable: false,
|
|
60
60
|
width: actionColumnConfig.defaultWidth,
|
|
61
61
|
resizable: true,
|
|
62
|
-
|
|
62
|
+
suppressHeaderMenuButton: true,
|
|
63
63
|
suppressMovable: false,
|
|
64
64
|
filter: false,
|
|
65
65
|
sortable: false,
|
|
@@ -69,8 +69,9 @@ export class FormatColumnInternalApi extends ApiBase {
|
|
|
69
69
|
// this.getFormatColumnsWithColumnScope(formatColumns)
|
|
70
70
|
(this.adaptable.api.scopeApi.scopeHasColumns(fc.Scope) ||
|
|
71
71
|
// this.getFormatColumnsWithDataTypeScope(formatColumns)
|
|
72
|
-
this.adaptable.api.scopeApi.scopeHasDataType(fc.Scope) ||
|
|
73
|
-
|
|
72
|
+
this.adaptable.api.scopeApi.scopeHasDataType(fc.Scope) ||
|
|
73
|
+
// this.getFormatColumnsWithAllScope(formatColumns)
|
|
74
|
+
this.adaptable.api.scopeApi.scopeIsAll(fc.Scope) || this.adaptable.api.scopeApi.scopeHasColumnType(fc.Scope))
|
|
74
75
|
);
|
|
75
76
|
});
|
|
76
77
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ApiBase } from '../Implementation/ApiBase';
|
|
2
2
|
import { CellDataChangedInfo } from '../../PredefinedConfig/Common/CellDataChangedInfo';
|
|
3
3
|
import { FreeTextColumn } from '../../PredefinedConfig/FreeTextColumnState';
|
|
4
|
+
import { ColDef } from '@ag-grid-community/core';
|
|
4
5
|
export declare class FreeTextColumnInternalApi extends ApiBase {
|
|
5
6
|
/**
|
|
6
7
|
* Checks if a User Edit was in a Free Text Column
|
|
@@ -12,4 +13,5 @@ export declare class FreeTextColumnInternalApi extends ApiBase {
|
|
|
12
13
|
* @param freeTextColumn FreeTextColumn to be checked
|
|
13
14
|
*/
|
|
14
15
|
getFreeTextColumnModuleReferences(freeTextColumn: FreeTextColumn): string[];
|
|
16
|
+
getColDefsForFreeTextColumns(): ColDef<any, any>[];
|
|
15
17
|
}
|