@adaptabletools/adaptable-cjs 18.0.0-canary.31 → 18.0.0-canary.33
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/package.json +1 -1
- package/src/AdaptableOptions/QuickSearchOptions.d.ts +1 -1
- package/src/Api/AdaptableApi.d.ts +2 -2
- package/src/Api/{ScopeApi.d.ts → ColumnScopeApi.d.ts} +2 -2
- package/src/Api/GridApi.d.ts +6 -1
- package/src/Api/Implementation/AdaptableApiImpl.d.ts +2 -2
- package/src/Api/Implementation/AdaptableApiImpl.js +3 -3
- package/src/Api/Implementation/AlertApiImpl.js +3 -3
- package/src/Api/Implementation/ApiBase.d.ts +2 -2
- package/src/Api/Implementation/ApiBase.js +2 -2
- package/src/Api/Implementation/ColumnFilterApiImpl.js +1 -1
- package/src/Api/Implementation/{ScopeApiImpl.d.ts → ColumnScopeApiImpl.d.ts} +2 -2
- package/src/Api/Implementation/{ScopeApiImpl.js → ColumnScopeApiImpl.js} +4 -4
- package/src/Api/Implementation/FlashingCellApiImpl.js +1 -1
- package/src/Api/Implementation/FormatColumnApiImpl.js +3 -3
- package/src/Api/Implementation/GridApiImpl.d.ts +1 -0
- package/src/Api/Implementation/GridApiImpl.js +5 -0
- package/src/Api/Implementation/NoteApiImpl.d.ts +1 -1
- package/src/Api/Implementation/NoteApiImpl.js +2 -2
- package/src/Api/Implementation/UserInterfaceApiImpl.js +3 -3
- package/src/Api/Internal/AdaptableInternalApi.js +1 -1
- package/src/Api/Internal/AlertInternalApi.js +3 -3
- package/src/Api/Internal/CustomSortInternalApi.js +1 -1
- package/src/Api/Internal/ExportInternalApi.js +1 -1
- package/src/Api/Internal/ExpressionInternalApi.js +1 -1
- package/src/Api/Internal/FormatColumnInternalApi.js +12 -13
- package/src/Api/Internal/StyledColumnInternalApi.js +1 -1
- package/src/Api/NoteApi.d.ts +1 -1
- package/src/PredefinedConfig/Common/AdaptableIcon.d.ts +1 -1
- package/src/PredefinedConfig/Common/RowScope.d.ts +2 -2
- package/src/PredefinedConfig/FormatColumnState.d.ts +1 -1
- package/src/PredefinedConfig/LayoutState.d.ts +1 -1
- package/src/Redux/ActionsReducers/NoteRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/NoteRedux.js +5 -5
- package/src/Strategy/AlertModule.js +2 -2
- package/src/Strategy/ExportModule.js +21 -4
- package/src/Strategy/FlashingCellModule.js +4 -4
- package/src/Strategy/FormatColumnModule.js +2 -2
- package/src/Strategy/NoteModule.js +3 -3
- package/src/Strategy/PlusMinusModule.js +3 -3
- package/src/Strategy/ShortcutModule.js +1 -1
- package/src/Strategy/StyledColumnModule.js +4 -4
- package/src/Strategy/Utilities/FormatColumn/getFormatColumnSettingsViewItems.js +1 -1
- package/src/Utilities/Services/CellPopupService.js +4 -4
- package/src/Utilities/Services/ReportService.js +2 -2
- package/src/Utilities/Services/ValidationService.js +2 -2
- package/src/View/Alert/AlertEntityRow.js +1 -1
- package/src/View/Alert/Wizard/AlertScopeWizardSection.js +2 -2
- package/src/View/Alert/Wizard/BaseAlertScopeWizardSection.js +1 -1
- package/src/View/ColumnInfo/ColumnInfo.js +1 -1
- package/src/View/Components/NewScopeComponent.js +2 -2
- package/src/View/Components/Popups/GridCellPopup/GridCellPopup.js +2 -5
- package/src/View/Components/RangesComponent.js +1 -1
- package/src/View/CustomSort/Wizard/CustomSortColumnWizardSection.js +1 -1
- package/src/View/DataChangeHistory/DataChangeHistoryGrid.js +1 -1
- package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.js +1 -1
- package/src/View/FormatColumn/Wizard/FormatColumnRuleWizardSection.js +1 -1
- package/src/View/FormatColumn/Wizard/FormatColumnScopeWizardSection.js +1 -1
- package/src/View/FormatColumn/Wizard/FormatColumnSettingsWizardSection.js +5 -5
- package/src/View/FormatColumn/Wizard/FormatColumnStyleWizardSection.js +1 -1
- package/src/View/Layout/Wizard/sections/RowGroupingSection.js +1 -1
- package/src/View/PlusMinus/PlusMinusSummary.js +2 -2
- package/src/View/StyledColumn/Wizard/StyledColumnBadgeSection.js +5 -7
- package/src/View/StyledColumn/Wizard/StyledColumnWizardColumnSection.js +1 -1
- package/src/View/StyledColumn/Wizard/StyledColumnWizardSettingsSection.js +5 -5
- package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/StyledColumnWizardStyleSection.js +1 -1
- package/src/agGrid/ActionColumnRenderer.js +10 -11
- package/src/agGrid/AdaptableAgGrid.js +2 -3
- package/src/agGrid/AgGridColumnAdapter.js +10 -10
- package/src/agGrid/AgGridMenuAdapter.js +5 -5
- package/src/agGrid/BadgeRenderer.js +6 -7
- package/src/agGrid/PercentBarRenderer.js +1 -1
- package/src/components/Accordion.d.ts +7 -0
- package/src/components/Accordion.js +41 -0
- package/src/components/icons/collapse-all.d.ts +3 -0
- package/src/components/icons/collapse-all.js +7 -0
- package/src/components/icons/csv.d.ts +3 -0
- package/src/components/icons/csv.js +7 -0
- package/src/components/icons/data-object.d.ts +3 -0
- package/src/components/icons/data-object.js +7 -0
- package/src/components/icons/excel.d.ts +3 -0
- package/src/components/icons/excel.js +8 -0
- package/src/components/icons/expand-all.d.ts +3 -0
- package/src/components/icons/expand-all.js +7 -0
- package/src/components/icons/index.js +10 -0
- package/src/env.js +2 -2
- package/src/metamodel/adaptable.metamodel.js +1 -1
- package/src/types.d.ts +1 -1
- package/tsconfig.cjs.tsbuildinfo +1 -1
- /package/src/Api/{ScopeApi.js → ColumnScopeApi.js} +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adaptabletools/adaptable-cjs",
|
|
3
|
-
"version": "18.0.0-canary.
|
|
3
|
+
"version": "18.0.0-canary.33",
|
|
4
4
|
"description": "Powerful data-agnostic HTML5 AG Grid extension which provides advanced, cutting-edge functionality to meet all DataGrid requirements",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"web-components",
|
|
@@ -33,7 +33,7 @@ export interface QuickSearchOptions<TData = any> {
|
|
|
33
33
|
*/
|
|
34
34
|
filterResultsAfterQuickSearch?: boolean;
|
|
35
35
|
/**
|
|
36
|
-
* Include Aggregrated Columns in
|
|
36
|
+
* Include Aggregrated Columns in Group Rows when Quick Searching (highlight only)
|
|
37
37
|
*
|
|
38
38
|
* @defaultValue false
|
|
39
39
|
* @gridInfoItem
|
|
@@ -29,7 +29,7 @@ import { ExpressionApi } from './ExpressionApi';
|
|
|
29
29
|
import { TeamSharingApi } from './TeamSharingApi';
|
|
30
30
|
import { ColumnApi } from './ColumnApi';
|
|
31
31
|
import { ApplicationApi } from './ApplicationApi';
|
|
32
|
-
import {
|
|
32
|
+
import { ColumnScopeApi } from './ColumnScopeApi';
|
|
33
33
|
import { PredicateApi } from './PredicateApi';
|
|
34
34
|
import { DataChangeHistoryApi } from './DataChangeHistoryApi';
|
|
35
35
|
import { FlashingCellApi } from './FlashingCellApi';
|
|
@@ -193,7 +193,7 @@ export interface AdaptableApi {
|
|
|
193
193
|
/**
|
|
194
194
|
* Manages the `Scope` object - used widely to determine where objects are applied
|
|
195
195
|
*/
|
|
196
|
-
|
|
196
|
+
columnScopeApi: ColumnScopeApi;
|
|
197
197
|
/**
|
|
198
198
|
* Provides access to the Shortcut Module
|
|
199
199
|
*/
|
|
@@ -2,9 +2,9 @@ import { AdaptableColumn } from '../PredefinedConfig/Common/AdaptableColumn';
|
|
|
2
2
|
import { ColumnScope, ScopeDataType } from '../PredefinedConfig/Common/ColumnScope';
|
|
3
3
|
import { CellColorRange } from '../PredefinedConfig/StyledColumnState';
|
|
4
4
|
/**
|
|
5
|
-
* Provides access to a suite of functions related to the `Scope` object
|
|
5
|
+
* Provides access to a suite of functions related to the `Column Scope` object
|
|
6
6
|
*/
|
|
7
|
-
export interface
|
|
7
|
+
export interface ColumnScopeApi {
|
|
8
8
|
/**
|
|
9
9
|
* True if Column is in given Scope
|
|
10
10
|
* @param column Column to check
|
package/src/Api/GridApi.d.ts
CHANGED
|
@@ -385,6 +385,11 @@ export interface GridApi {
|
|
|
385
385
|
* @param rowNode Node to check
|
|
386
386
|
*/
|
|
387
387
|
isGroupRowNode(rowNode: IRowNode): boolean;
|
|
388
|
+
/**
|
|
389
|
+
* Whether given Row Node is in a Smmary Row
|
|
390
|
+
* @param rowNode Node to check
|
|
391
|
+
*/
|
|
392
|
+
isSummaryNode(rowNode: IRowNode): boolean;
|
|
388
393
|
/**
|
|
389
394
|
* Whether Quick Filter is available in the Grid
|
|
390
395
|
*/
|
|
@@ -480,7 +485,7 @@ export interface GridApi {
|
|
|
480
485
|
*/
|
|
481
486
|
refreshRowNodes(rowNodes: IRowNode[]): void;
|
|
482
487
|
/**
|
|
483
|
-
* Forces a re-render of all
|
|
488
|
+
* Forces a re-render of all Group Rows (including aggregations)
|
|
484
489
|
*/
|
|
485
490
|
refreshGroupRowNodes(): void;
|
|
486
491
|
/**
|
|
@@ -31,7 +31,7 @@ import { ExpressionApi } from '../ExpressionApi';
|
|
|
31
31
|
import { TeamSharingApi } from '../TeamSharingApi';
|
|
32
32
|
import { ColumnApi } from '../ColumnApi';
|
|
33
33
|
import { ApplicationApi } from '../ApplicationApi';
|
|
34
|
-
import {
|
|
34
|
+
import { ColumnScopeApi } from '../ColumnScopeApi';
|
|
35
35
|
import { PredicateApi } from '../PredicateApi';
|
|
36
36
|
import { DataChangeHistoryApi } from '../DataChangeHistoryApi';
|
|
37
37
|
import { FlashingCellApi } from '../FlashingCellApi';
|
|
@@ -86,7 +86,7 @@ export declare class AdaptableApiImpl implements AdaptableApi {
|
|
|
86
86
|
styledColumnApi: StyledColumnApi;
|
|
87
87
|
toolPanelApi: ToolPanelApi;
|
|
88
88
|
teamSharingApi: TeamSharingApi;
|
|
89
|
-
|
|
89
|
+
columnScopeApi: ColumnScopeApi;
|
|
90
90
|
dataChangeHistoryApi: DataChangeHistoryApi;
|
|
91
91
|
chartingApi: ChartingApi;
|
|
92
92
|
statusBarApi: StatusBarApi;
|
|
@@ -31,7 +31,7 @@ const ScheduleApiImpl_1 = require("./ScheduleApiImpl");
|
|
|
31
31
|
const TeamSharingApiImpl_1 = require("./TeamSharingApiImpl");
|
|
32
32
|
const ColumnApiImpl_1 = require("./ColumnApiImpl");
|
|
33
33
|
const ApplicationApiImpl_1 = require("./ApplicationApiImpl");
|
|
34
|
-
const
|
|
34
|
+
const ColumnScopeApiImpl_1 = require("./ColumnScopeApiImpl");
|
|
35
35
|
const DataChangeHistoryApiImpl_1 = require("./DataChangeHistoryApiImpl");
|
|
36
36
|
const ExpressionApiImpl_1 = require("./ExpressionApiImpl");
|
|
37
37
|
const FlashingCellApiImpl_1 = require("./FlashingCellApiImpl");
|
|
@@ -93,7 +93,7 @@ class AdaptableApiImpl {
|
|
|
93
93
|
this.styledColumnApi = new StyledColumnApiImpl_1.StyledColumnApiImpl(adaptable);
|
|
94
94
|
this.toolPanelApi = new ToolPanelApiImpl_1.ToolPanelApiImpl(adaptable);
|
|
95
95
|
this.teamSharingApi = new TeamSharingApiImpl_1.TeamSharingApiImpl(adaptable);
|
|
96
|
-
this.
|
|
96
|
+
this.columnScopeApi = new ColumnScopeApiImpl_1.ColumnScopeApiImpl(adaptable);
|
|
97
97
|
this.dataChangeHistoryApi = new DataChangeHistoryApiImpl_1.DataChangeHistoryApiImpl(adaptable);
|
|
98
98
|
this.chartingApi = new ChartingApiImpl_1.ChartingApiImpl(adaptable);
|
|
99
99
|
this.statusBarApi = new StatusBarApiImpl_1.StatusBarApiImpl(adaptable);
|
|
@@ -147,7 +147,7 @@ class AdaptableApiImpl {
|
|
|
147
147
|
this.expressionApi = null;
|
|
148
148
|
this.quickSearchApi = null;
|
|
149
149
|
this.scheduleApi = null;
|
|
150
|
-
this.
|
|
150
|
+
this.columnScopeApi = null;
|
|
151
151
|
this.settingsPanelApi = null;
|
|
152
152
|
this.shortcutApi = null;
|
|
153
153
|
this.smartEditApi = null;
|
|
@@ -166,7 +166,7 @@ class AlertApiImpl extends ApiBase_1.ApiBase {
|
|
|
166
166
|
}
|
|
167
167
|
evaluateAlertDefinitions(alertDefinitions) {
|
|
168
168
|
const filterScopeAllDefinitions = (alertDefinition) => {
|
|
169
|
-
if (this.getAdaptableApi().
|
|
169
|
+
if (this.getAdaptableApi().columnScopeApi.scopeIsAll(alertDefinition.Scope) &&
|
|
170
170
|
!this.getAdaptableApi().expressionApi.getAdaptableQueryExpression(alertDefinition.Rule)) {
|
|
171
171
|
// we don't support scope ALL without an expression
|
|
172
172
|
// the predicates for scope ALL do NOT make any sense for a programmatic evaluation
|
|
@@ -201,7 +201,7 @@ class AlertApiImpl extends ApiBase_1.ApiBase {
|
|
|
201
201
|
// if there is an Expression defined, extract only the columns from there (in that case the Scope would be 'All' anyway)
|
|
202
202
|
// columns referenced in rule expression
|
|
203
203
|
const ruleExpression = this.getAdaptableApi().expressionApi.getAdaptableQueryExpression(alertDefinition.Rule);
|
|
204
|
-
if (this.getAdaptableApi().
|
|
204
|
+
if (this.getAdaptableApi().columnScopeApi.scopeIsAll(alertDefinition.Scope) &&
|
|
205
205
|
StringExtensions_1.default.IsNotNullOrEmpty(ruleExpression)) {
|
|
206
206
|
// return only first referenced column (otherwise we would generate multiple alerts for the same row)
|
|
207
207
|
const queryColumns = this.getAdaptableApi()
|
|
@@ -212,7 +212,7 @@ class AlertApiImpl extends ApiBase_1.ApiBase {
|
|
|
212
212
|
else {
|
|
213
213
|
// otherwise return all columns for given scope
|
|
214
214
|
return this.getAdaptableApi()
|
|
215
|
-
.
|
|
215
|
+
.columnScopeApi.getColumnsForScope(alertDefinition.Scope)
|
|
216
216
|
.map((adaptableColumn) => adaptableColumn.columnId);
|
|
217
217
|
}
|
|
218
218
|
}
|
|
@@ -7,7 +7,7 @@ import { ModuleInfo } from '../../Strategy/Interface/IModule';
|
|
|
7
7
|
import { AdaptableOptions } from '../../AdaptableOptions/AdaptableOptions';
|
|
8
8
|
import { AdaptableApi } from '../AdaptableApi';
|
|
9
9
|
import { ExportOptions } from '../../AdaptableOptions/ExportOptions';
|
|
10
|
-
import { ActionColumnApi, ActionColumnOptions, ActionRowApi, ActionRowOptions, AlertApi, AlertOptions, ApplicationApi, BulkUpdateApi, CalculatedColumnApi, CalendarApi, CalendarOptions, CellSummaryApi, CellSummaryOptions, ChartingApi, ChartingOptions, ColumnApi, ColumnFilterApi, ColumnFilterOptions, ColumnOptions, CommentOptions, ConfigApi, ContainerOptions, CustomSortApi, CustomSortOptions, DashboardApi, DashboardOptions, DataChangeHistoryApi, DataChangeHistoryOptions, DataSetApi, DataSetOptions, EditOptions, EntitlementApi, EntitlementOptions, EventApi, ExportApi, ExpressionApi, ExpressionOptions, Fdc3Api, Fdc3Options, FlashingCellApi, FlashingCellOptions, FormatColumnApi, FormatColumnOptions, FreeTextColumnApi, GridApi, GridFilterApi, GroupingOptions, LayoutApi, LayoutAssociatedObject, LayoutOptions, MenuOptions, NamedQueryApi, NoteOptions, NotificationsOptions, PluginsApi, PlusMinusApi, PredicateApi, PredicateOptions, QuickSearchApi, QuickSearchOptions, ScheduleApi,
|
|
10
|
+
import { ActionColumnApi, ActionColumnOptions, ActionRowApi, ActionRowOptions, AlertApi, AlertOptions, ApplicationApi, BulkUpdateApi, CalculatedColumnApi, CalendarApi, CalendarOptions, CellSummaryApi, CellSummaryOptions, ChartingApi, ChartingOptions, ColumnApi, ColumnFilterApi, ColumnFilterOptions, ColumnOptions, CommentOptions, ConfigApi, ContainerOptions, CustomSortApi, CustomSortOptions, DashboardApi, DashboardOptions, DataChangeHistoryApi, DataChangeHistoryOptions, DataSetApi, DataSetOptions, EditOptions, EntitlementApi, EntitlementOptions, EventApi, ExportApi, ExpressionApi, ExpressionOptions, Fdc3Api, Fdc3Options, FlashingCellApi, FlashingCellOptions, FormatColumnApi, FormatColumnOptions, FreeTextColumnApi, GridApi, GridFilterApi, GroupingOptions, LayoutApi, LayoutAssociatedObject, LayoutOptions, MenuOptions, NamedQueryApi, NoteOptions, NotificationsOptions, PluginsApi, PlusMinusApi, PredicateApi, PredicateOptions, QuickSearchApi, QuickSearchOptions, ScheduleApi, ColumnScopeApi, SettingsPanelApi, SettingsPanelOptions, ShortcutApi, SmartEditApi, StateOptions, StatusBarApi, StyledColumnApi, SystemStatusApi, TeamSharingApi, TeamSharingOptions, ThemeApi, ToolPanelApi, ToolPanelOptions, UserInterfaceApi, UserInterfaceOptions } from '../../types';
|
|
11
11
|
import { ModuleParams } from '../../View/Components/SharedProps/ModuleViewPopupProps';
|
|
12
12
|
export declare abstract class ApiBase {
|
|
13
13
|
protected adaptable: IAdaptable;
|
|
@@ -123,7 +123,7 @@ export declare abstract class ApiBase {
|
|
|
123
123
|
protected getStyledColumnApi(): StyledColumnApi;
|
|
124
124
|
protected getToolPanelApi(): ToolPanelApi;
|
|
125
125
|
protected getTeamSharingApi(): TeamSharingApi;
|
|
126
|
-
protected
|
|
126
|
+
protected getColumnScopeApi(): ColumnScopeApi;
|
|
127
127
|
protected getDataChangeHistoryApi(): DataChangeHistoryApi;
|
|
128
128
|
protected getChartingApi(): ChartingApi;
|
|
129
129
|
protected getStatusBarApi(): StatusBarApi;
|
|
@@ -315,8 +315,8 @@ class ApiBase {
|
|
|
315
315
|
getTeamSharingApi() {
|
|
316
316
|
return this.getAdaptableApi().teamSharingApi;
|
|
317
317
|
}
|
|
318
|
-
|
|
319
|
-
return this.getAdaptableApi().
|
|
318
|
+
getColumnScopeApi() {
|
|
319
|
+
return this.getAdaptableApi().columnScopeApi;
|
|
320
320
|
}
|
|
321
321
|
getDataChangeHistoryApi() {
|
|
322
322
|
return this.getAdaptableApi().dataChangeHistoryApi;
|
|
@@ -18,7 +18,7 @@ class ColumnFilterApiImpl extends ApiBase_1.ApiBase {
|
|
|
18
18
|
};
|
|
19
19
|
return this.getAdaptableApi()
|
|
20
20
|
.predicateApi.internalApi.getFilterPredicateDefs(scope)
|
|
21
|
-
.filter((predicate) => this.getAdaptableApi().
|
|
21
|
+
.filter((predicate) => this.getAdaptableApi().columnScopeApi.isColumnInScope(column, predicate.columnScope));
|
|
22
22
|
}
|
|
23
23
|
getFilterPredicateDefsForColumnId(columnId) {
|
|
24
24
|
const column = this.getAdaptableApi().columnApi.getColumnWithColumnId(columnId);
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { ApiBase } from './ApiBase';
|
|
2
2
|
import { AdaptableColumn } from '../../PredefinedConfig/Common/AdaptableColumn';
|
|
3
3
|
import { ColumnScope, ScopeDataType } from '../../PredefinedConfig/Common/ColumnScope';
|
|
4
|
-
import {
|
|
4
|
+
import { ColumnScopeApi } from '../ColumnScopeApi';
|
|
5
5
|
import { CellColorRange } from '../../PredefinedConfig/StyledColumnState';
|
|
6
|
-
export declare class
|
|
6
|
+
export declare class ColumnScopeApiImpl extends ApiBase implements ColumnScopeApi {
|
|
7
7
|
isColumnInScope(column: AdaptableColumn | undefined, scope: ColumnScope | undefined): boolean;
|
|
8
8
|
getColumnsForScope(scope: ColumnScope): AdaptableColumn[];
|
|
9
9
|
getScopeDescription(scope: ColumnScope): string;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.ColumnScopeApiImpl = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const ApiBase_1 = require("./ApiBase");
|
|
6
6
|
const ArrayExtensions_1 = tslib_1.__importDefault(require("../../Utilities/Extensions/ArrayExtensions"));
|
|
7
7
|
const UIHelper_1 = require("../../View/UIHelper");
|
|
8
|
-
class
|
|
8
|
+
class ColumnScopeApiImpl extends ApiBase_1.ApiBase {
|
|
9
9
|
isColumnInScope(column, scope) {
|
|
10
10
|
if (!column) {
|
|
11
11
|
return false;
|
|
@@ -280,7 +280,7 @@ class ScopeApiImpl extends ApiBase_1.ApiBase {
|
|
|
280
280
|
return false;
|
|
281
281
|
}
|
|
282
282
|
createCellColorRangesForScope(scope) {
|
|
283
|
-
let distinctColumnsValues = this.getAdaptableApi().gridApi.internalApi.getDistinctRawValuesForColumn(this.getAdaptableApi().
|
|
283
|
+
let distinctColumnsValues = this.getAdaptableApi().gridApi.internalApi.getDistinctRawValuesForColumn(this.getAdaptableApi().columnScopeApi.getSingleColumnInScope(scope));
|
|
284
284
|
let minValue = Math.min(...distinctColumnsValues);
|
|
285
285
|
let maxValue = Math.max(...distinctColumnsValues);
|
|
286
286
|
const ranges = [];
|
|
@@ -317,4 +317,4 @@ class ScopeApiImpl extends ApiBase_1.ApiBase {
|
|
|
317
317
|
return false;
|
|
318
318
|
}
|
|
319
319
|
}
|
|
320
|
-
exports.
|
|
320
|
+
exports.ColumnScopeApiImpl = ColumnScopeApiImpl;
|
|
@@ -83,7 +83,7 @@ class FlashingCellApiImpl extends ApiBase_1.ApiBase {
|
|
|
83
83
|
getFlashingCellPredicateDefsForScope(scope) {
|
|
84
84
|
return this.getAdaptableApi()
|
|
85
85
|
.predicateApi.internalApi.getFlashingCellPredicateDefs(scope)
|
|
86
|
-
.filter((predicateDef) => this.getAdaptableApi().
|
|
86
|
+
.filter((predicateDef) => this.getAdaptableApi().columnScopeApi.isScopeInScope(scope, predicateDef.columnScope));
|
|
87
87
|
}
|
|
88
88
|
clearAllFlashingCells() {
|
|
89
89
|
this.dispatchAction(SystemRedux.SystemFlashingCellDeleteAll());
|
|
@@ -79,13 +79,13 @@ class FormatColumnApiImpl extends ApiBase_1.ApiBase {
|
|
|
79
79
|
this.showModulePopup(ModuleConstants.FormatColumnModuleId);
|
|
80
80
|
}
|
|
81
81
|
getFormatColumnsWithAllScope(formatColumns) {
|
|
82
|
-
return formatColumns.filter((fc) => this.getAdaptableApi().
|
|
82
|
+
return formatColumns.filter((fc) => this.getAdaptableApi().columnScopeApi.scopeIsAll(fc.Scope));
|
|
83
83
|
}
|
|
84
84
|
getFormatColumnsWithDataTypeScope(formatColumns) {
|
|
85
|
-
return formatColumns.filter((fc) => this.getAdaptableApi().
|
|
85
|
+
return formatColumns.filter((fc) => this.getAdaptableApi().columnScopeApi.scopeHasDataType(fc.Scope));
|
|
86
86
|
}
|
|
87
87
|
getFormatColumnsWithColumnScope(formatColumns) {
|
|
88
|
-
return formatColumns.filter((fc) => this.getAdaptableApi().
|
|
88
|
+
return formatColumns.filter((fc) => this.getAdaptableApi().columnScopeApi.scopeHasColumns(fc.Scope));
|
|
89
89
|
}
|
|
90
90
|
hasCustomDisplayFormatter(formatColumn) {
|
|
91
91
|
var _a;
|
|
@@ -99,6 +99,7 @@ export declare class GridApiImpl extends ApiBase implements GridApi {
|
|
|
99
99
|
isGridRowGrouped(): boolean;
|
|
100
100
|
isGridInPivotMode(): boolean;
|
|
101
101
|
isGroupRowNode(rowNode: IRowNode): boolean;
|
|
102
|
+
isSummaryNode(rowNode: IRowNode): boolean;
|
|
102
103
|
isQuickFilterAvailable(): boolean;
|
|
103
104
|
redrawGrid(): void;
|
|
104
105
|
getGridCellsForRawValue(columnId: string, rawValue: any): GridCell[] | undefined;
|
|
@@ -10,6 +10,7 @@ const GridInternalApi_1 = require("../Internal/GridInternalApi");
|
|
|
10
10
|
const ArrayExtensions_1 = tslib_1.__importDefault(require("../../Utilities/Extensions/ArrayExtensions"));
|
|
11
11
|
const logDeprecation_1 = require("../../Utilities/logDeprecation");
|
|
12
12
|
const windowFactory_1 = require("../../View/Components/Popups/WindowPopups/windowFactory");
|
|
13
|
+
const RowSummary_1 = require("../../PredefinedConfig/Common/RowSummary");
|
|
13
14
|
class GridApiImpl extends ApiBase_1.ApiBase {
|
|
14
15
|
constructor(adaptable) {
|
|
15
16
|
super(adaptable);
|
|
@@ -378,6 +379,10 @@ class GridApiImpl extends ApiBase_1.ApiBase {
|
|
|
378
379
|
isGroupRowNode(rowNode) {
|
|
379
380
|
return this.adaptable.isGroupRowNode(rowNode);
|
|
380
381
|
}
|
|
382
|
+
isSummaryNode(rowNode) {
|
|
383
|
+
var _a;
|
|
384
|
+
return (_a = rowNode === null || rowNode === void 0 ? void 0 : rowNode.data) === null || _a === void 0 ? void 0 : _a[RowSummary_1.ROW_SUMMARY_ROW_ID];
|
|
385
|
+
}
|
|
381
386
|
isQuickFilterAvailable() {
|
|
382
387
|
return this.adaptable.isQuickFilterAvailable();
|
|
383
388
|
}
|
|
@@ -13,6 +13,6 @@ export declare class NoteApiImpl extends ApiBase implements NoteApi {
|
|
|
13
13
|
deleteNote(note: AdaptableNote): void;
|
|
14
14
|
getNoteState(): NoteState;
|
|
15
15
|
getAllNotes(): AdaptableNotes;
|
|
16
|
-
|
|
16
|
+
getNoteForCell(address: CellAddress): AdaptableNote;
|
|
17
17
|
getNoteByUuid(uuid: string): AdaptableNote | undefined;
|
|
18
18
|
}
|
|
@@ -35,8 +35,8 @@ class NoteApiImpl extends ApiBase_1.ApiBase {
|
|
|
35
35
|
getAllNotes() {
|
|
36
36
|
return this.getNoteState().Notes;
|
|
37
37
|
}
|
|
38
|
-
|
|
39
|
-
return NoteRedux.
|
|
38
|
+
getNoteForCell(address) {
|
|
39
|
+
return NoteRedux.GetNoteSelector(this.getAdaptableState().Note, address);
|
|
40
40
|
}
|
|
41
41
|
getNoteByUuid(uuid) {
|
|
42
42
|
return this.getAllNotes().find((note) => note.Uuid === uuid);
|
|
@@ -46,21 +46,21 @@ class UserInterfaceApiImpl extends ApiBase_1.ApiBase {
|
|
|
46
46
|
// columns id
|
|
47
47
|
permittedValuesItem = permittedValues.find((permittedValue) => {
|
|
48
48
|
return ('ColumnIds' in permittedValue.scope &&
|
|
49
|
-
this.getAdaptableApi().
|
|
49
|
+
this.getAdaptableApi().columnScopeApi.isColumnInScope(column, permittedValue.scope));
|
|
50
50
|
});
|
|
51
51
|
if (permittedValuesItem) {
|
|
52
52
|
return permittedValuesItem;
|
|
53
53
|
}
|
|
54
54
|
permittedValuesItem = permittedValues.find((permittedValue) => {
|
|
55
55
|
return ('DataTypes' in permittedValue.scope &&
|
|
56
|
-
this.getAdaptableApi().
|
|
56
|
+
this.getAdaptableApi().columnScopeApi.isColumnInScope(column, permittedValue.scope));
|
|
57
57
|
});
|
|
58
58
|
if (permittedValuesItem) {
|
|
59
59
|
return permittedValuesItem;
|
|
60
60
|
}
|
|
61
61
|
permittedValuesItem = permittedValues.find((permittedValue) => {
|
|
62
62
|
return ('All' in permittedValue.scope &&
|
|
63
|
-
this.getAdaptableApi().
|
|
63
|
+
this.getAdaptableApi().columnScopeApi.isColumnInScope(column, permittedValue.scope));
|
|
64
64
|
});
|
|
65
65
|
if (permittedValuesItem) {
|
|
66
66
|
return permittedValuesItem;
|
|
@@ -425,7 +425,7 @@ class AdaptableInternalApi extends ApiBase_1.ApiBase {
|
|
|
425
425
|
}
|
|
426
426
|
// lastly filter by scope
|
|
427
427
|
if (scope) {
|
|
428
|
-
locatedAdaptableObjects = locatedAdaptableObjects.filter((adaptableObject) => this.getAdaptableApi().
|
|
428
|
+
locatedAdaptableObjects = locatedAdaptableObjects.filter((adaptableObject) => this.getAdaptableApi().columnScopeApi.isScopeInScope(adaptableObject.Scope, scope));
|
|
429
429
|
}
|
|
430
430
|
return locatedAdaptableObjects;
|
|
431
431
|
}
|
|
@@ -213,7 +213,7 @@ class AlertInternalApi extends ApiBase_1.ApiBase {
|
|
|
213
213
|
getAlertPredicateDefsForScope(scope) {
|
|
214
214
|
return this.getPredicateApi()
|
|
215
215
|
.internalApi.getAlertPredicateDefs(scope)
|
|
216
|
-
.filter((predicateDef) => this.
|
|
216
|
+
.filter((predicateDef) => this.getColumnScopeApi().isScopeInScope(scope, predicateDef.columnScope));
|
|
217
217
|
}
|
|
218
218
|
/**
|
|
219
219
|
* Returns a description of an Alert Definition
|
|
@@ -227,7 +227,7 @@ class AlertInternalApi extends ApiBase_1.ApiBase {
|
|
|
227
227
|
if (alertDefinition.MessageText != null) {
|
|
228
228
|
return alertDefinition.MessageText;
|
|
229
229
|
}
|
|
230
|
-
let scopeDescription = this.
|
|
230
|
+
let scopeDescription = this.getColumnScopeApi().getScopeDescription(alertDefinition.Scope);
|
|
231
231
|
let ruleDescription = this.getAlertRuleDescription(alertDefinition);
|
|
232
232
|
return scopeDescription + ' - ' + ruleDescription;
|
|
233
233
|
}
|
|
@@ -419,7 +419,7 @@ class AlertInternalApi extends ApiBase_1.ApiBase {
|
|
|
419
419
|
getAlertDefinitionsForCellDataChange(dataChangedEvent) {
|
|
420
420
|
const allActiveNonReactiveDefinitions = this.getActiveNonReactiveAlertDefinitions();
|
|
421
421
|
let relatedAlertDefinitions = allActiveNonReactiveDefinitions
|
|
422
|
-
.filter((v) => this.getAdaptableApi().
|
|
422
|
+
.filter((v) => this.getAdaptableApi().columnScopeApi.isColumnInScope(dataChangedEvent.column, v.Scope))
|
|
423
423
|
.filter((alertDefinition) => !(0, AdaptableQuery_1.isReactiveQuery)(alertDefinition.Rule));
|
|
424
424
|
let triggeredAlerts = [];
|
|
425
425
|
if (ArrayExtensions_1.default.IsNotNullOrEmpty(relatedAlertDefinitions)) {
|
|
@@ -6,7 +6,7 @@ class CustomSortInternalApi extends ApiBase_1.ApiBase {
|
|
|
6
6
|
getCustomSortComparer(columnId) {
|
|
7
7
|
var _a;
|
|
8
8
|
const column = this.getColumnApi().getColumnWithColumnId(columnId);
|
|
9
|
-
return (_a = this.getCustomSortOptions().customSortComparers) === null || _a === void 0 ? void 0 : _a.find((csc) => this.getAdaptableApi().
|
|
9
|
+
return (_a = this.getCustomSortOptions().customSortComparers) === null || _a === void 0 ? void 0 : _a.find((csc) => this.getAdaptableApi().columnScopeApi.isColumnInScope(column, csc.scope));
|
|
10
10
|
}
|
|
11
11
|
getDefaultCustomSortComparer(columnId, columnValues) {
|
|
12
12
|
// have to return a function that may not have access to this
|
|
@@ -24,7 +24,7 @@ class ExportInternalApi extends ApiBase_1.ApiBase {
|
|
|
24
24
|
break;
|
|
25
25
|
case 'ScopeColumns':
|
|
26
26
|
// use the Scope object which will tell us if the Column is relevant
|
|
27
|
-
if (!this.getAdaptableApi().
|
|
27
|
+
if (!this.getAdaptableApi().columnScopeApi.isColumnInScopeColumns(cellDataChangedInfo.column, report.Scope)) {
|
|
28
28
|
return false;
|
|
29
29
|
}
|
|
30
30
|
break;
|
|
@@ -44,7 +44,7 @@ class ExpressionInternalApi extends ApiBase_1.ApiBase {
|
|
|
44
44
|
context.predicates = predicates;
|
|
45
45
|
// need to find a way to get the columns in the predicates
|
|
46
46
|
// cand do later
|
|
47
|
-
// this.getAdaptableApi().
|
|
47
|
+
// this.getAdaptableApi().columnScopeApi.getColumnsForScope();
|
|
48
48
|
}
|
|
49
49
|
return !evaluateExpressionExternallyFn(context);
|
|
50
50
|
}
|
|
@@ -7,7 +7,6 @@ const StringExtensions_1 = tslib_1.__importDefault(require("../../Utilities/Exte
|
|
|
7
7
|
const FormatHelper_1 = tslib_1.__importDefault(require("../../Utilities/Helpers/FormatHelper"));
|
|
8
8
|
const ObjectFactory_1 = tslib_1.__importDefault(require("../../Utilities/ObjectFactory"));
|
|
9
9
|
const ModuleConstants = tslib_1.__importStar(require("../../Utilities/Constants/ModuleConstants"));
|
|
10
|
-
const RowSummary_1 = require("../../PredefinedConfig/Common/RowSummary");
|
|
11
10
|
class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
12
11
|
/**
|
|
13
12
|
* Retrieves all Format Columns in Adaptable State with the `Style` property set
|
|
@@ -64,7 +63,7 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
64
63
|
return this.getFormatColumnsWithStyleForColumn(column, config).filter((formatColumn) => { var _a; return StringExtensions_1.default.IsNotNullOrEmpty((_a = formatColumn === null || formatColumn === void 0 ? void 0 : formatColumn.Style) === null || _a === void 0 ? void 0 : _a.ClassName); });
|
|
65
64
|
}
|
|
66
65
|
getFormatColumnWithColumnInScope(formatColumns, column) {
|
|
67
|
-
return this.getFormatColumnInColumnScope(formatColumns).filter((scopedFormatColumn) => this.getAdaptableApi().
|
|
66
|
+
return this.getFormatColumnInColumnScope(formatColumns).filter((scopedFormatColumn) => this.getAdaptableApi().columnScopeApi.isColumnInScope(column, scopedFormatColumn.Scope));
|
|
68
67
|
}
|
|
69
68
|
// TODO is this really needed, I don't think it achieves anything
|
|
70
69
|
getFormatColumnInColumnScope(formatColumns) {
|
|
@@ -72,11 +71,11 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
72
71
|
return formatColumns.filter((fc) => {
|
|
73
72
|
return (
|
|
74
73
|
// this.getFormatColumnsWithColumnScope(formatColumns)
|
|
75
|
-
(this.getAdaptableApi().
|
|
74
|
+
(this.getAdaptableApi().columnScopeApi.scopeHasColumns(fc.Scope) ||
|
|
76
75
|
// this.getFormatColumnsWithDataTypeScope(formatColumns)
|
|
77
|
-
this.getAdaptableApi().
|
|
76
|
+
this.getAdaptableApi().columnScopeApi.scopeHasDataType(fc.Scope) ||
|
|
78
77
|
// this.getFormatColumnsWithAllScope(formatColumns)
|
|
79
|
-
this.getAdaptableApi().
|
|
78
|
+
this.getAdaptableApi().columnScopeApi.scopeIsAll(fc.Scope) || this.getAdaptableApi().columnScopeApi.scopeHasColumnType(fc.Scope))
|
|
80
79
|
);
|
|
81
80
|
});
|
|
82
81
|
}
|
|
@@ -149,7 +148,7 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
149
148
|
getFormatColumnDefsForScope(scope) {
|
|
150
149
|
return this.getAdaptableApi()
|
|
151
150
|
.predicateApi.internalApi.getFormatColumnPredicateDefs(scope)
|
|
152
|
-
.filter((predicateDef) => this.getAdaptableApi().
|
|
151
|
+
.filter((predicateDef) => this.getAdaptableApi().columnScopeApi.isScopeInScope(scope, predicateDef.columnScope));
|
|
153
152
|
}
|
|
154
153
|
/**
|
|
155
154
|
* Checks if format column is relevant for a given cell (intersection of given AdaptableColumn and RowNode)
|
|
@@ -159,26 +158,26 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
159
158
|
* @param params
|
|
160
159
|
*/
|
|
161
160
|
formatColumnShouldRender(formatColumn, column, rowNode, cellValue) {
|
|
162
|
-
var _a, _b, _c, _d, _e
|
|
161
|
+
var _a, _b, _c, _d, _e;
|
|
163
162
|
// suspended is important to be first
|
|
164
163
|
if (formatColumn.IsSuspended) {
|
|
165
164
|
return false;
|
|
166
165
|
}
|
|
167
|
-
const isSummaryNode = (
|
|
166
|
+
const isSummaryNode = this.getAdaptableApi().gridApi.isSummaryNode(rowNode);
|
|
168
167
|
const isGroupedRowNode = this.getAdaptableApi().gridApi.isGroupRowNode(rowNode);
|
|
169
168
|
// For Summary Rows cannot be excluded
|
|
170
169
|
if (isSummaryNode) {
|
|
171
|
-
if ((
|
|
170
|
+
if ((_a = formatColumn.RowScope) === null || _a === void 0 ? void 0 : _a.ExcludeSummaryRows) {
|
|
172
171
|
return false;
|
|
173
172
|
}
|
|
174
173
|
}
|
|
175
174
|
else if (isGroupedRowNode) {
|
|
176
|
-
if ((
|
|
175
|
+
if ((_b = formatColumn.RowScope) === null || _b === void 0 ? void 0 : _b.ExcludeGroupRows) {
|
|
177
176
|
return false;
|
|
178
177
|
}
|
|
179
178
|
}
|
|
180
179
|
else {
|
|
181
|
-
if ((
|
|
180
|
+
if ((_c = formatColumn.RowScope) === null || _c === void 0 ? void 0 : _c.ExcludeDataRows) {
|
|
182
181
|
return false;
|
|
183
182
|
}
|
|
184
183
|
}
|
|
@@ -186,7 +185,7 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
186
185
|
return true;
|
|
187
186
|
}
|
|
188
187
|
// first run the predicate
|
|
189
|
-
if (formatColumn.Rule.Predicates && ((
|
|
188
|
+
if (formatColumn.Rule.Predicates && ((_e = (_d = formatColumn.Rule) === null || _d === void 0 ? void 0 : _d.Predicates) === null || _e === void 0 ? void 0 : _e.length)) {
|
|
190
189
|
const predicateDefHandlerContext = Object.assign({ value: cellValue, oldValue: null, displayValue: cellValue, node: rowNode, column: column }, this.getAdaptableApi().internalApi.buildBaseContext());
|
|
191
190
|
return this.evaluatePredicate(formatColumn, predicateDefHandlerContext);
|
|
192
191
|
} // then run the Expression
|
|
@@ -255,7 +254,7 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
255
254
|
const columnsThatNeedRefresh = new Set();
|
|
256
255
|
this.getFormatColumnsDependentOnColumns(impactedColumnIds).forEach((formatColumn) => {
|
|
257
256
|
this.getAdaptableApi()
|
|
258
|
-
.
|
|
257
|
+
.columnScopeApi.getColumnsForScope(formatColumn.Scope)
|
|
259
258
|
.forEach((col) => {
|
|
260
259
|
columnsThatNeedRefresh.add(col.columnId);
|
|
261
260
|
});
|
|
@@ -278,7 +278,7 @@ class StyledColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
278
278
|
};
|
|
279
279
|
return this.getAdaptableApi()
|
|
280
280
|
.predicateApi.internalApi.getBadgeStylePredicateDefs(scope)
|
|
281
|
-
.filter((predicate) => this.getAdaptableApi().
|
|
281
|
+
.filter((predicate) => this.getAdaptableApi().columnScopeApi.isColumnInScope(column, predicate.columnScope));
|
|
282
282
|
}
|
|
283
283
|
}
|
|
284
284
|
exports.StyledColumnInternalApi = StyledColumnInternalApi;
|
package/src/Api/NoteApi.d.ts
CHANGED
|
@@ -39,7 +39,7 @@ export interface NoteApi {
|
|
|
39
39
|
* Gets all Notes for a cell
|
|
40
40
|
* @param CellAddress note position
|
|
41
41
|
*/
|
|
42
|
-
|
|
42
|
+
getNoteForCell(CellAddress: CellAddress): AdaptableNote;
|
|
43
43
|
/**
|
|
44
44
|
* Returns a Note by uuid
|
|
45
45
|
* @param uuid note uuid
|
|
@@ -54,4 +54,4 @@ export interface AdaptableBaseIcon {
|
|
|
54
54
|
/**
|
|
55
55
|
* All AdapTable System Icon names
|
|
56
56
|
*/
|
|
57
|
-
export type AdaptableSystemIconName = 'add' | 'alert' | 'building' | 'laptop' | 'arrow-down' | 'arrow-left' | 'arrow-right' | 'arrow-up' | 'arrow-up-long' | 'arrow-down-long' | 'arrow-expand' | 'paperclip' | 'unfilled-circle' | 'boolean-list' | 'broadcast' | 'brush' | 'spanner' | 'edit-table' | 'chart-and-grid' | 'calendar' | 'call' | 'cells' | 'fdc3' | 'flag' | 'chart' | 'chat' | 'check' | 'check-circle' | 'checked' | 'clone' | 'close' | 'cloud-upload' | 'collapse' | 'column-add' | 'columns' | 'filter-list' | 'copy' | 'comment' | 'comments' | 'contains' | 'dashboard' | 'data-set' | 'date-range' | 'delete' | 'division' | 'dock' | 'dollar' | 'drag' | 'edit' | 'ends-with' | 'equals' | 'equation' | 'error' | 'expand' | 'exponent' | 'export' | 'export-data' | 'fast-backward' | 'fast-forward' | 'filter' | 'filter-off' | 'lightning' | 'folder' | 'folder-open' | 'folder-shared' | 'color-palette' | 'horizontal-lines' | 'function' | 'greater-than' | 'greater-than-or-equal' | 'history' | 'home' | 'import-export' | 'info' | 'brain' | 'download' | 'grid' | 'interactions' | 'less-than' | 'less-than-or-equal' | 'list' | 'logout' | 'mail' | 'menu' | 'minus' | 'multiplication' | 'money' | 'newpage' | 'news' | 'filled-circle' | 'not-contains' | 'not-equal' | 'open-in-new' | 'order' | 'organisation' | 'pause' | 'percent' | 'percent-tag' | 'person' | 'contact' | 'pie-chart' | 'play' | 'plus' | 'add-circle' | 'search' | 'search-table' | 'select-all' | 'select-off' | 'select-fwd' | 'quote' | 'refresh' | 'regex' | 'reminder' | 'save' | 'schedule' | 'science' | 'settings' | 'link' | 'sort-asc' | 'sort-desc' | 'spark-line' | 'resume' | 'starts-with' | 'assignment' | 'statusbar' | 'stop' | 'traffic-lights' | 'tab-unselected' | 'theme' | 'clipboard' | 'target' | 'triangle-down' | 'triangle-up' | 'unchecked' | 'undo' | 'downloaded' | 'upload' | 'warning' | 'gradient' | 'badge' | 'italic' | 'bold' | 'align-left' | 'align-right' | 'align-center' | 'align-justify' | 'underline' | 'strikethrough' | 'overline' | 'case-upper' | 'case-lower' | 'case-sentence' | 'visibility-on' | 'visibility-off' | 'visibility-off-bold' | 'visibility-on-bold' | 'note' | 'import' | 'grid-filter' | 'grid-info' | 'rows';
|
|
57
|
+
export type AdaptableSystemIconName = 'add' | 'alert' | 'building' | 'laptop' | 'arrow-down' | 'arrow-left' | 'arrow-right' | 'arrow-up' | 'arrow-up-long' | 'arrow-down-long' | 'arrow-expand' | 'paperclip' | 'unfilled-circle' | 'boolean-list' | 'broadcast' | 'brush' | 'spanner' | 'edit-table' | 'chart-and-grid' | 'calendar' | 'call' | 'cells' | 'fdc3' | 'flag' | 'chart' | 'chat' | 'check' | 'check-circle' | 'checked' | 'clone' | 'close' | 'cloud-upload' | 'collapse' | 'column-add' | 'columns' | 'filter-list' | 'copy' | 'comment' | 'comments' | 'contains' | 'dashboard' | 'json' | 'data-set' | 'date-range' | 'delete' | 'division' | 'dock' | 'dollar' | 'drag' | 'edit' | 'ends-with' | 'equals' | 'equation' | 'error' | 'excel' | 'expand' | 'exponent' | 'export' | 'export-data' | 'fast-backward' | 'fast-forward' | 'filter' | 'filter-off' | 'lightning' | 'folder' | 'folder-open' | 'folder-shared' | 'color-palette' | 'horizontal-lines' | 'function' | 'greater-than' | 'greater-than-or-equal' | 'history' | 'home' | 'import-export' | 'info' | 'brain' | 'download' | 'grid' | 'interactions' | 'less-than' | 'less-than-or-equal' | 'list' | 'logout' | 'mail' | 'menu' | 'minus' | 'multiplication' | 'money' | 'newpage' | 'news' | 'filled-circle' | 'not-contains' | 'not-equal' | 'open-in-new' | 'order' | 'organisation' | 'pause' | 'percent' | 'percent-tag' | 'person' | 'contact' | 'pie-chart' | 'play' | 'plus' | 'add-circle' | 'search' | 'search-table' | 'select-all' | 'select-off' | 'select-fwd' | 'quote' | 'refresh' | 'regex' | 'reminder' | 'save' | 'schedule' | 'science' | 'settings' | 'link' | 'sort-asc' | 'sort-desc' | 'spark-line' | 'resume' | 'starts-with' | 'assignment' | 'statusbar' | 'stop' | 'traffic-lights' | 'tab-unselected' | 'theme' | 'clipboard' | 'target' | 'triangle-down' | 'triangle-up' | 'unchecked' | 'undo' | 'downloaded' | 'upload' | 'warning' | 'gradient' | 'badge' | 'italic' | 'bold' | 'align-left' | 'align-right' | 'align-center' | 'align-justify' | 'underline' | 'strikethrough' | 'overline' | 'case-upper' | 'case-lower' | 'case-sentence' | 'visibility-on' | 'visibility-off' | 'visibility-off-bold' | 'visibility-on-bold' | 'note' | 'import' | 'grid-filter' | 'grid-info' | 'csv' | 'rows' | 'expand-all' | 'collapse-all';
|
|
@@ -46,7 +46,7 @@ export interface FormatColumn extends SuspendableObject {
|
|
|
46
46
|
*/
|
|
47
47
|
RowScope?: RowScope;
|
|
48
48
|
/**
|
|
49
|
-
* @deprecated FormatColumns now apply to
|
|
49
|
+
* @deprecated FormatColumns now apply to Group Rows by default; use RowScope for more control
|
|
50
50
|
*/
|
|
51
51
|
IncludeGroupedRows?: never;
|
|
52
52
|
}
|
|
@@ -56,7 +56,7 @@ export interface Layout extends AdaptableObject {
|
|
|
56
56
|
*/
|
|
57
57
|
ExpandedRowGroupValues?: any[];
|
|
58
58
|
/**
|
|
59
|
-
* Columns showing aggregated values in
|
|
59
|
+
* Columns showing aggregated values in Group Rows; 1st value in record is Column name, 2nd is either aggfunc (e.g. sum, avg etc.) or 'true' (to use default aggfunc)
|
|
60
60
|
*/
|
|
61
61
|
AggregationColumns?: AggregationColumns;
|
|
62
62
|
/**
|
|
@@ -34,5 +34,5 @@ export declare const NoteEdit: (note: AdaptableNote) => AdaptableNoteEditAction;
|
|
|
34
34
|
export declare const NoteDelete: (note: AdaptableNote) => AdaptableNoteDeleteAction;
|
|
35
35
|
export declare const NoteReady: (note: NoteState) => NoteReadyAction;
|
|
36
36
|
export declare const GetAllNotesSelector: (state: NoteState) => AdaptableNote[];
|
|
37
|
-
export declare const
|
|
37
|
+
export declare const GetNoteSelector: (state: NoteState, address: CellAddress) => AdaptableNote;
|
|
38
38
|
export declare const NoteReducer: Redux.Reducer<NoteState>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.NoteReducer = exports.
|
|
3
|
+
exports.NoteReducer = exports.GetNoteSelector = exports.GetAllNotesSelector = exports.NoteReady = exports.NoteDelete = exports.NoteEdit = exports.NoteAdd = exports.NOTE_READY = exports.NOTE_DELETE = exports.NOTE_EDIT = exports.NOTE_ADD = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const AdaptableHelper_1 = tslib_1.__importDefault(require("../../Utilities/Helpers/AdaptableHelper"));
|
|
6
6
|
const GeneralConstants_1 = require("../../Utilities/Constants/GeneralConstants");
|
|
@@ -42,12 +42,12 @@ const NoteReady = (note) => ({
|
|
|
42
42
|
exports.NoteReady = NoteReady;
|
|
43
43
|
const GetAllNotesSelector = (state) => state.Notes;
|
|
44
44
|
exports.GetAllNotesSelector = GetAllNotesSelector;
|
|
45
|
-
const
|
|
45
|
+
const GetNoteSelector = (state, address) => {
|
|
46
46
|
var _a;
|
|
47
47
|
if (!address) {
|
|
48
|
-
return
|
|
48
|
+
return null;
|
|
49
49
|
}
|
|
50
|
-
return ((_a = state === null || state === void 0 ? void 0 : state.Notes) !== null && _a !== void 0 ? _a : []).
|
|
50
|
+
return ((_a = state === null || state === void 0 ? void 0 : state.Notes) !== null && _a !== void 0 ? _a : []).find((note) => {
|
|
51
51
|
if (note.PrimaryKeyValue === address.PrimaryKeyValue && note.ColumnId === address.ColumnId) {
|
|
52
52
|
// happy check
|
|
53
53
|
return true;
|
|
@@ -61,7 +61,7 @@ const GetNotesSelector = (state, address) => {
|
|
|
61
61
|
return false;
|
|
62
62
|
});
|
|
63
63
|
};
|
|
64
|
-
exports.
|
|
64
|
+
exports.GetNoteSelector = GetNoteSelector;
|
|
65
65
|
const initialState = {
|
|
66
66
|
Notes: GeneralConstants_1.EMPTY_ARRAY,
|
|
67
67
|
};
|