@adaptabletools/adaptable-cjs 18.0.0-canary.8 → 18.0.0-canary.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/base.css.map +1 -1
- package/index.css.map +1 -1
- package/package.json +1 -1
- package/src/AdaptableInterfaces/IAdaptable.d.ts +8 -1
- package/src/AdaptableOptions/AdaptableOptions.d.ts +1 -1
- package/src/Api/ConfigApi.d.ts +1 -1
- package/src/Api/GridApi.d.ts +4 -0
- package/src/Api/Implementation/CommentsApiImpl.d.ts +4 -0
- package/src/Api/Implementation/CommentsApiImpl.js +5 -0
- package/src/Api/Implementation/ConfigApiImpl.js +6 -3
- package/src/Api/Implementation/GridApiImpl.d.ts +1 -0
- package/src/Api/Implementation/GridApiImpl.js +13 -0
- package/src/Api/Implementation/LayoutApiImpl.d.ts +2 -4
- package/src/Api/Implementation/LayoutApiImpl.js +15 -14
- package/src/Api/Implementation/NotesApiImpl.d.ts +4 -0
- package/src/Api/Implementation/NotesApiImpl.js +5 -0
- package/src/Api/Implementation/ScopeApiImpl.d.ts +2 -0
- package/src/Api/Implementation/ScopeApiImpl.js +20 -7
- package/src/Api/Internal/CalculatedColumnInternalApi.js +1 -1
- package/src/Api/Internal/CommentsInternalApi.d.ts +4 -0
- package/src/Api/Internal/CommentsInternalApi.js +17 -0
- package/src/Api/Internal/FormatColumnInternalApi.js +3 -2
- package/src/Api/Internal/FreeTextColumnInternalApi.js +1 -1
- package/src/Api/Internal/NotesInternalApi.d.ts +4 -0
- package/src/Api/Internal/NotesInternalApi.js +17 -0
- package/src/Api/LayoutApi.d.ts +11 -8
- package/src/Api/ScopeApi.d.ts +10 -0
- 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/RowSummary.d.ts +7 -0
- package/src/PredefinedConfig/Common/RowSummary.js +4 -0
- package/src/PredefinedConfig/LayoutState.d.ts +5 -0
- package/src/PredefinedConfig/SystemState.d.ts +7 -0
- package/src/Redux/ActionsReducers/LayoutRedux.d.ts +9 -0
- package/src/Redux/ActionsReducers/LayoutRedux.js +22 -1
- package/src/Redux/ActionsReducers/SystemRedux.d.ts +5 -0
- package/src/Redux/ActionsReducers/SystemRedux.js +16 -3
- package/src/Redux/Store/AdaptableStore.js +11 -0
- package/src/Redux/Store/Interface/IAdaptableStore.d.ts +2 -2
- package/src/Strategy/CellSummaryModule.d.ts +1 -0
- package/src/Strategy/CellSummaryModule.js +50 -21
- package/src/Strategy/CommentsModule.js +3 -0
- package/src/Strategy/LayoutModule.d.ts +7 -0
- package/src/Strategy/LayoutModule.js +102 -3
- package/src/Strategy/NotesModule.js +3 -4
- package/src/Utilities/ExpressionFunctions/aggregatedScalarExpressionFunctions.d.ts +2 -1
- package/src/Utilities/ExpressionFunctions/aggregatedScalarExpressionFunctions.js +294 -0
- package/src/Utilities/ExpressionFunctions/scalarAggregationHelper.js +1 -1
- package/src/Utilities/Extensions/ArrayExtensions.d.ts +2 -0
- package/src/Utilities/Extensions/ArrayExtensions.js +6 -1
- package/src/Utilities/ObjectFactory.js +6 -6
- package/src/Utilities/Services/AggregatedScalarLiveValue.d.ts +3 -2
- package/src/Utilities/Services/AggregatedScalarLiveValue.js +11 -8
- package/src/Utilities/Services/Interface/IQueryLanguageService.d.ts +1 -1
- package/src/Utilities/Services/LicenseService/index.js +4 -1
- package/src/Utilities/Services/QueryLanguageService.d.ts +1 -1
- package/src/Utilities/Services/QueryLanguageService.js +2 -1
- package/src/Utilities/Services/SummaryService.d.ts +19 -0
- package/src/Utilities/Services/SummaryService.js +33 -0
- package/src/View/Components/AdaptableDateInput/index.d.ts +1 -1
- package/src/View/Components/NewScopeComponent.js +32 -1
- package/src/View/Layout/TransposedPopup.js +7 -6
- package/src/agGrid/AdaptableAgGrid.d.ts +15 -1
- package/src/agGrid/AdaptableAgGrid.js +131 -23
- package/src/agGrid/AgGridAdapter.d.ts +1 -0
- package/src/agGrid/AgGridAdapter.js +8 -0
- package/src/agGrid/AgGridColumnAdapter.js +14 -3
- package/src/components/ColorPicker/ColorPicker.d.ts +1 -1
- package/src/components/Datepicker/index.d.ts +1 -1
- package/src/components/Input/index.d.ts +1 -1
- package/src/components/List/ListGroupItem/index.d.ts +1 -1
- package/src/components/icons/index.js +2 -0
- package/src/components/icons/rows.d.ts +3 -0
- package/src/components/icons/rows.js +7 -0
- package/src/env.js +2 -2
- package/src/metamodel/adaptable.metamodel.d.ts +8 -0
- package/src/metamodel/adaptable.metamodel.js +18 -0
- package/src/parser/src/types.d.ts +5 -0
- package/tsconfig.cjs.tsbuildinfo +1 -1
- package/src/View/Components/ScopeComponent.d.ts +0 -24
- package/src/View/Components/ScopeComponent.js +0 -138
- package/src/View/Export/Wizard/ReportScopeWizard.d.ts +0 -17
- package/src/View/Export/Wizard/ReportScopeWizard.js +0 -52
package/src/Api/ConfigApi.d.ts
CHANGED
package/src/Api/GridApi.d.ts
CHANGED
|
@@ -516,4 +516,8 @@ export interface GridApi {
|
|
|
516
516
|
* @deprecated use `getRowCount()` instead
|
|
517
517
|
*/
|
|
518
518
|
getVisibleRowCount(): number;
|
|
519
|
+
/**
|
|
520
|
+
* Opens a window with a transposed view of Grid
|
|
521
|
+
*/
|
|
522
|
+
showTransposedView(transposedColumnId: string, hideTransposedColumn?: boolean): void;
|
|
519
523
|
}
|
|
@@ -2,7 +2,11 @@ import { ApiBase } from './ApiBase';
|
|
|
2
2
|
import { CellAddress } from '../../PredefinedConfig/CellAddress';
|
|
3
3
|
import { CommentThread, AdaptableComment } from '../../types';
|
|
4
4
|
import { CommentApi } from '../CommentApi';
|
|
5
|
+
import { CommentsInternalApi } from '../Internal/CommentsInternalApi';
|
|
6
|
+
import { IAdaptable } from '../../AdaptableInterfaces/IAdaptable';
|
|
5
7
|
export declare class CommentsApiImpl extends ApiBase implements CommentApi {
|
|
8
|
+
internalApi: CommentsInternalApi;
|
|
9
|
+
constructor(adaptable: IAdaptable);
|
|
6
10
|
getComments(address: CellAddress): AdaptableComment[];
|
|
7
11
|
getCommentThread(address: CellAddress): CommentThread | undefined;
|
|
8
12
|
getCommentThreads(): CommentThread[];
|
|
@@ -6,7 +6,12 @@ const CommentRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/C
|
|
|
6
6
|
const ApiBase_1 = require("./ApiBase");
|
|
7
7
|
const ObjectFactory_1 = tslib_1.__importDefault(require("../../Utilities/ObjectFactory"));
|
|
8
8
|
const AdaptableHelper_1 = tslib_1.__importDefault(require("../../Utilities/Helpers/AdaptableHelper"));
|
|
9
|
+
const CommentsInternalApi_1 = require("../Internal/CommentsInternalApi");
|
|
9
10
|
class CommentsApiImpl extends ApiBase_1.ApiBase {
|
|
11
|
+
constructor(adaptable) {
|
|
12
|
+
super(adaptable);
|
|
13
|
+
this.internalApi = new CommentsInternalApi_1.CommentsInternalApi(adaptable);
|
|
14
|
+
}
|
|
10
15
|
getComments(address) {
|
|
11
16
|
return CommentRedux.GetCommentsSelector(this.getAdaptableState().Comment, address);
|
|
12
17
|
}
|
|
@@ -140,16 +140,19 @@ class ConfigApiImpl extends ApiBase_1.ApiBase {
|
|
|
140
140
|
});
|
|
141
141
|
promise
|
|
142
142
|
.then(() => {
|
|
143
|
-
this.adaptable.updateColumnModelAndRefreshGrid();
|
|
143
|
+
this.adaptable.updateColumnModelAndRefreshGrid({ skipColDefsRefresh: true });
|
|
144
144
|
this.adaptable.setLayout();
|
|
145
145
|
this.adaptable.api.userInterfaceApi.hideLoadingScreen();
|
|
146
146
|
})
|
|
147
147
|
.then(() => {
|
|
148
148
|
// resolve main(result) promise
|
|
149
149
|
resolve();
|
|
150
|
-
}, () => {
|
|
150
|
+
}, (error) => {
|
|
151
151
|
// reject main(result) promise
|
|
152
|
-
reject();
|
|
152
|
+
reject(error);
|
|
153
|
+
})
|
|
154
|
+
.catch((e) => {
|
|
155
|
+
this.logError('Error setting Adaptable State Key', e);
|
|
153
156
|
});
|
|
154
157
|
});
|
|
155
158
|
});
|
|
@@ -130,4 +130,5 @@ export declare class GridApiImpl extends ApiBase implements GridApi {
|
|
|
130
130
|
openGridInfoSettingsPanel(): void;
|
|
131
131
|
getAgGridRowModelType(): RowModelType;
|
|
132
132
|
getVisibleRowCount(): number;
|
|
133
|
+
showTransposedView(transposedColumnId: string, hideTransposedColumn?: boolean): void;
|
|
133
134
|
}
|
|
@@ -9,6 +9,7 @@ const ModuleConstants = tslib_1.__importStar(require("../../Utilities/Constants/
|
|
|
9
9
|
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
|
+
const windowFactory_1 = require("../../View/Components/Popups/WindowPopups/windowFactory");
|
|
12
13
|
class GridApiImpl extends ApiBase_1.ApiBase {
|
|
13
14
|
constructor(adaptable) {
|
|
14
15
|
super(adaptable);
|
|
@@ -519,5 +520,17 @@ class GridApiImpl extends ApiBase_1.ApiBase {
|
|
|
519
520
|
(0, logDeprecation_1.logDeprecation)(this.adaptable.logger, 'GridApi', 'getVisibleRowCount', 'getRowCount');
|
|
520
521
|
return this.getRowCount();
|
|
521
522
|
}
|
|
523
|
+
showTransposedView(transposedColumnId, hideTransposedColumn) {
|
|
524
|
+
this.adaptable.api.internalApi.showPopupWindow({
|
|
525
|
+
id: windowFactory_1.WINDOW_SHOW_TRANSPOSED_VIEW,
|
|
526
|
+
factoryId: windowFactory_1.WINDOW_SHOW_TRANSPOSED_VIEW,
|
|
527
|
+
title: 'Transposed View',
|
|
528
|
+
icon: 'grid',
|
|
529
|
+
popupProps: {
|
|
530
|
+
transposedColumnId,
|
|
531
|
+
hideTransposedColumn,
|
|
532
|
+
},
|
|
533
|
+
});
|
|
534
|
+
}
|
|
522
535
|
}
|
|
523
536
|
exports.GridApiImpl = GridApiImpl;
|
|
@@ -41,6 +41,8 @@ export declare class LayoutApiImpl extends ApiBase implements LayoutApi {
|
|
|
41
41
|
removeColumnFromCurrentLayout(columnId: string): void;
|
|
42
42
|
removeColumnFromAllLayouts(columnId: string): void;
|
|
43
43
|
removeColumnFromLayout(columnId: string, layoutName: string): void;
|
|
44
|
+
addColumnToLayout(columnId: string, layoutName: string): void;
|
|
45
|
+
addColumnToCurrentLayout(columnId: string): void;
|
|
44
46
|
getLayoutSupportedFeatures(): {
|
|
45
47
|
RowGroupedColumns: boolean;
|
|
46
48
|
AggregationColumns: boolean;
|
|
@@ -48,8 +50,4 @@ export declare class LayoutApiImpl extends ApiBase implements LayoutApi {
|
|
|
48
50
|
ColumnFilters: boolean;
|
|
49
51
|
ColumnSorts: boolean;
|
|
50
52
|
};
|
|
51
|
-
showTransposePopup(config: {
|
|
52
|
-
transposedColumnId: string;
|
|
53
|
-
hideTransposedColumn?: boolean;
|
|
54
|
-
}): void;
|
|
55
53
|
}
|
|
@@ -13,7 +13,6 @@ const Uuid_1 = require("../../PredefinedConfig/Uuid");
|
|
|
13
13
|
const GeneralConstants_1 = require("../../Utilities/Constants/GeneralConstants");
|
|
14
14
|
const PopupRedux_1 = require("../../Redux/ActionsReducers/PopupRedux");
|
|
15
15
|
const LayoutInternalApi_1 = require("../Internal/LayoutInternalApi");
|
|
16
|
-
const windowFactory_1 = require("../../View/Components/Popups/WindowPopups/windowFactory");
|
|
17
16
|
class LayoutApiImpl extends ApiBase_1.ApiBase {
|
|
18
17
|
constructor(adaptable) {
|
|
19
18
|
super(adaptable);
|
|
@@ -226,6 +225,21 @@ class LayoutApiImpl extends ApiBase_1.ApiBase {
|
|
|
226
225
|
}
|
|
227
226
|
}
|
|
228
227
|
}
|
|
228
|
+
addColumnToLayout(columnId, layoutName) {
|
|
229
|
+
const column = this.getAdaptableApi().columnApi.getColumnWithColumnId(columnId);
|
|
230
|
+
if (column) {
|
|
231
|
+
const layout = this.getLayoutByName(layoutName);
|
|
232
|
+
if (layout) {
|
|
233
|
+
if (!layout.Columns.includes(columnId)) {
|
|
234
|
+
this.dispatchAction(LayoutRedux.LayoutAddColumn(layoutName, columnId));
|
|
235
|
+
this.getAdaptableApi().columnApi.showColumn(columnId);
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
}
|
|
240
|
+
addColumnToCurrentLayout(columnId) {
|
|
241
|
+
this.addColumnToLayout(columnId, this.getCurrentLayoutName());
|
|
242
|
+
}
|
|
229
243
|
getLayoutSupportedFeatures() {
|
|
230
244
|
const layoutSupportedFeatures = {
|
|
231
245
|
RowGroupedColumns: true,
|
|
@@ -241,18 +255,5 @@ class LayoutApiImpl extends ApiBase_1.ApiBase {
|
|
|
241
255
|
}
|
|
242
256
|
return layoutSupportedFeatures;
|
|
243
257
|
}
|
|
244
|
-
showTransposePopup(config) {
|
|
245
|
-
const { transposedColumnId, hideTransposedColumn } = config;
|
|
246
|
-
this.adaptable.api.internalApi.showPopupWindow({
|
|
247
|
-
id: windowFactory_1.WINDOW_SHOW_TRANSPOSED_VIEW,
|
|
248
|
-
factoryId: windowFactory_1.WINDOW_SHOW_TRANSPOSED_VIEW,
|
|
249
|
-
title: 'Transpose View',
|
|
250
|
-
icon: 'grid',
|
|
251
|
-
popupProps: {
|
|
252
|
-
transposedColumnId,
|
|
253
|
-
hideTransposedColumn,
|
|
254
|
-
},
|
|
255
|
-
});
|
|
256
|
-
}
|
|
257
258
|
}
|
|
258
259
|
exports.LayoutApiImpl = LayoutApiImpl;
|
|
@@ -2,7 +2,11 @@ import { ApiBase } from './ApiBase';
|
|
|
2
2
|
import { NotesApi } from '../NotesApi';
|
|
3
3
|
import { AdaptableNote, AdaptableNotes, NotesState } from '../../PredefinedConfig/NotesState';
|
|
4
4
|
import { CellAddress } from '../../PredefinedConfig/CellAddress';
|
|
5
|
+
import { IAdaptable } from '../../AdaptableInterfaces/IAdaptable';
|
|
6
|
+
import { NotesInternalApi } from '../Internal/NotesInternalApi';
|
|
5
7
|
export declare class NotesApiImpl extends ApiBase implements NotesApi {
|
|
8
|
+
internalApi: NotesInternalApi;
|
|
9
|
+
constructor(adaptable: IAdaptable);
|
|
6
10
|
addNote(noteStr: string, primaryKeyValue: any, columnId: string): void;
|
|
7
11
|
editNote(note: AdaptableNote): void;
|
|
8
12
|
updateNoteText(noteStr: string, note: AdaptableNote): void;
|
|
@@ -4,7 +4,12 @@ exports.NotesApiImpl = void 0;
|
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const ApiBase_1 = require("./ApiBase");
|
|
6
6
|
const NotesRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/NotesRedux"));
|
|
7
|
+
const NotesInternalApi_1 = require("../Internal/NotesInternalApi");
|
|
7
8
|
class NotesApiImpl extends ApiBase_1.ApiBase {
|
|
9
|
+
constructor(adaptable) {
|
|
10
|
+
super(adaptable);
|
|
11
|
+
this.internalApi = new NotesInternalApi_1.NotesInternalApi(adaptable);
|
|
12
|
+
}
|
|
8
13
|
addNote(noteStr, primaryKeyValue, columnId) {
|
|
9
14
|
const note = {
|
|
10
15
|
Text: noteStr,
|
|
@@ -10,6 +10,7 @@ export declare class ScopeApiImpl extends ApiBase implements ScopeApi {
|
|
|
10
10
|
scopeIsEmpty(scope: AdaptableScope): boolean;
|
|
11
11
|
scopeIsAll(scope: AdaptableScope): boolean;
|
|
12
12
|
scopeHasDataType(scope: AdaptableScope): boolean;
|
|
13
|
+
scopeHasColumnType(scope: AdaptableScope): boolean;
|
|
13
14
|
scopeHasOnlyBooleanDataType(scope: AdaptableScope): boolean;
|
|
14
15
|
scopeHasColumns(scope: AdaptableScope): boolean;
|
|
15
16
|
isSingleColumnScope(scope: AdaptableScope): boolean;
|
|
@@ -21,6 +22,7 @@ export declare class ScopeApiImpl extends ApiBase implements ScopeApi {
|
|
|
21
22
|
isPrimaryKeyColumnInScopeColumns(scope: AdaptableScope): boolean;
|
|
22
23
|
getScopeToString(scope: AdaptableScope): string;
|
|
23
24
|
getColumnIdsInScope(scope: AdaptableScope): string[] | undefined;
|
|
25
|
+
getColumnTypesInScope(scope: AdaptableScope): string[] | undefined;
|
|
24
26
|
getDataTypesInScope(scope: AdaptableScope): ScopeDataType[] | undefined;
|
|
25
27
|
isColumnInNumericScope(column: AdaptableColumn, scope: AdaptableScope): boolean;
|
|
26
28
|
isColumnInStringsScope(column: AdaptableColumn, scope: AdaptableScope): boolean;
|
|
@@ -17,6 +17,10 @@ class ScopeApiImpl extends ApiBase_1.ApiBase {
|
|
|
17
17
|
if ('DataTypes' in scope && scope.DataTypes.includes(column.dataType)) {
|
|
18
18
|
return true;
|
|
19
19
|
}
|
|
20
|
+
if ('ColumnTypes' in scope &&
|
|
21
|
+
scope.ColumnTypes.some((columnType) => { var _a; return (_a = column.columnTypes) === null || _a === void 0 ? void 0 : _a.includes(columnType); })) {
|
|
22
|
+
return true;
|
|
23
|
+
}
|
|
20
24
|
if ('ColumnIds' in scope && scope.ColumnIds.includes(column.columnId)) {
|
|
21
25
|
return true;
|
|
22
26
|
}
|
|
@@ -31,13 +35,7 @@ class ScopeApiImpl extends ApiBase_1.ApiBase {
|
|
|
31
35
|
return columns;
|
|
32
36
|
}
|
|
33
37
|
return columns.filter((c) => {
|
|
34
|
-
|
|
35
|
-
return true;
|
|
36
|
-
}
|
|
37
|
-
if ('ColumnIds' in scope && scope.ColumnIds.includes(c.columnId)) {
|
|
38
|
-
return true;
|
|
39
|
-
}
|
|
40
|
-
return false;
|
|
38
|
+
return this.isColumnInScope(c, scope);
|
|
41
39
|
});
|
|
42
40
|
}
|
|
43
41
|
getScopeDescription(scope) {
|
|
@@ -48,6 +46,9 @@ class ScopeApiImpl extends ApiBase_1.ApiBase {
|
|
|
48
46
|
// do we need a true check here?
|
|
49
47
|
return 'Columns: All';
|
|
50
48
|
}
|
|
49
|
+
if ('ColumnTypes' in scope) {
|
|
50
|
+
return ((scope.ColumnTypes.length > 0 ? 'ColumnTypes' : 'ColumnType') + ': ' + scope.ColumnTypes.join(', '));
|
|
51
|
+
}
|
|
51
52
|
if ('DataTypes' in scope) {
|
|
52
53
|
return ((scope.DataTypes.length > 0 ? 'DataTypes' : 'DataType') + ': ' + scope.DataTypes.join(', '));
|
|
53
54
|
}
|
|
@@ -71,6 +72,9 @@ class ScopeApiImpl extends ApiBase_1.ApiBase {
|
|
|
71
72
|
scopeHasDataType(scope) {
|
|
72
73
|
return scope !== undefined && 'DataTypes' in scope;
|
|
73
74
|
}
|
|
75
|
+
scopeHasColumnType(scope) {
|
|
76
|
+
return scope !== undefined && 'ColumnTypes' in scope;
|
|
77
|
+
}
|
|
74
78
|
scopeHasOnlyBooleanDataType(scope) {
|
|
75
79
|
var _a;
|
|
76
80
|
return 'DataTypes' in scope && ((_a = scope.DataTypes) === null || _a === void 0 ? void 0 : _a.length) == 1 && scope.DataTypes[0] == 'Boolean';
|
|
@@ -124,6 +128,9 @@ class ScopeApiImpl extends ApiBase_1.ApiBase {
|
|
|
124
128
|
if ('All' in scope) {
|
|
125
129
|
return 'Columns: All';
|
|
126
130
|
}
|
|
131
|
+
if ('ColumnTypes' in scope) {
|
|
132
|
+
return 'ColumnTypes: ' + scope.ColumnTypes.join(',');
|
|
133
|
+
}
|
|
127
134
|
if ('DataTypes' in scope) {
|
|
128
135
|
return 'DataTypes: ' + scope.DataTypes.join(',');
|
|
129
136
|
}
|
|
@@ -144,6 +151,12 @@ class ScopeApiImpl extends ApiBase_1.ApiBase {
|
|
|
144
151
|
}
|
|
145
152
|
return undefined;
|
|
146
153
|
}
|
|
154
|
+
getColumnTypesInScope(scope) {
|
|
155
|
+
if (scope !== undefined && 'ColumnTypes' in scope) {
|
|
156
|
+
return scope.ColumnTypes;
|
|
157
|
+
}
|
|
158
|
+
return undefined;
|
|
159
|
+
}
|
|
147
160
|
getDataTypesInScope(scope) {
|
|
148
161
|
if (scope !== undefined && 'DataTypes' in scope) {
|
|
149
162
|
return scope.DataTypes;
|
|
@@ -133,7 +133,7 @@ class CalculatedColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
133
133
|
? calculatedColumn.FriendlyName
|
|
134
134
|
: calculatedColumn.ColumnId,
|
|
135
135
|
colId: calculatedColumn.ColumnId,
|
|
136
|
-
hide:
|
|
136
|
+
hide: false,
|
|
137
137
|
editable: false,
|
|
138
138
|
width: calculatedColumnSettings.Width,
|
|
139
139
|
enableValue: calculatedColumnSettings.Aggregatable,
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CommentsInternalApi = void 0;
|
|
4
|
+
const ApiBase_1 = require("../Implementation/ApiBase");
|
|
5
|
+
class CommentsInternalApi extends ApiBase_1.ApiBase {
|
|
6
|
+
areCommentsAvailable() {
|
|
7
|
+
const currentLayout = this.getLayoutApi().getCurrentLayout();
|
|
8
|
+
if (currentLayout.EnablePivot) {
|
|
9
|
+
return false;
|
|
10
|
+
}
|
|
11
|
+
if (currentLayout.RowGroupedColumns) {
|
|
12
|
+
return false;
|
|
13
|
+
}
|
|
14
|
+
return true;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
exports.CommentsInternalApi = CommentsInternalApi;
|
|
@@ -73,8 +73,9 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
73
73
|
// this.getFormatColumnsWithColumnScope(formatColumns)
|
|
74
74
|
(this.adaptable.api.scopeApi.scopeHasColumns(fc.Scope) ||
|
|
75
75
|
// this.getFormatColumnsWithDataTypeScope(formatColumns)
|
|
76
|
-
this.adaptable.api.scopeApi.scopeHasDataType(fc.Scope) ||
|
|
77
|
-
|
|
76
|
+
this.adaptable.api.scopeApi.scopeHasDataType(fc.Scope) ||
|
|
77
|
+
// this.getFormatColumnsWithAllScope(formatColumns)
|
|
78
|
+
this.adaptable.api.scopeApi.scopeIsAll(fc.Scope) || this.adaptable.api.scopeApi.scopeHasColumnType(fc.Scope))
|
|
78
79
|
);
|
|
79
80
|
});
|
|
80
81
|
}
|
|
@@ -69,7 +69,7 @@ class FreeTextColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
69
69
|
headerName: freeTextColumn.FriendlyName || freeTextColumn.ColumnId,
|
|
70
70
|
colId: freeTextColumn.ColumnId,
|
|
71
71
|
editable: true,
|
|
72
|
-
hide:
|
|
72
|
+
hide: false,
|
|
73
73
|
width: freeTextColumnSettings.Width,
|
|
74
74
|
enableValue: freeTextColumnSettings.Aggregatable,
|
|
75
75
|
filter: freeTextColumnSettings.Filterable,
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.NotesInternalApi = void 0;
|
|
4
|
+
const ApiBase_1 = require("../Implementation/ApiBase");
|
|
5
|
+
class NotesInternalApi extends ApiBase_1.ApiBase {
|
|
6
|
+
areNotesAvailable() {
|
|
7
|
+
const currentLayout = this.getLayoutApi().getCurrentLayout();
|
|
8
|
+
if (currentLayout.EnablePivot) {
|
|
9
|
+
return false;
|
|
10
|
+
}
|
|
11
|
+
if (currentLayout.RowGroupedColumns) {
|
|
12
|
+
return false;
|
|
13
|
+
}
|
|
14
|
+
return true;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
exports.NotesInternalApi = NotesInternalApi;
|
package/src/Api/LayoutApi.d.ts
CHANGED
|
@@ -163,6 +163,17 @@ export interface LayoutApi {
|
|
|
163
163
|
* @param layoutName layout from which to remove Column
|
|
164
164
|
*/
|
|
165
165
|
removeColumnFromLayout(columnId: string, layoutName: string): void;
|
|
166
|
+
/**
|
|
167
|
+
* Adds a Column to a given Layout
|
|
168
|
+
* @param columnId Column to add
|
|
169
|
+
* @param layoutName layout to which to add Column
|
|
170
|
+
*/
|
|
171
|
+
addColumnToLayout(columnId: string, layoutName: string): void;
|
|
172
|
+
/**
|
|
173
|
+
* Adds a Column to Current Layout
|
|
174
|
+
* @param columnId Column to add
|
|
175
|
+
*/
|
|
176
|
+
addColumnToCurrentLayout(columnId: string): void;
|
|
166
177
|
/**
|
|
167
178
|
* Returns what the layout supports.
|
|
168
179
|
* This takes into account the data-source.
|
|
@@ -174,12 +185,4 @@ export interface LayoutApi {
|
|
|
174
185
|
ColumnFilters: boolean;
|
|
175
186
|
ColumnSorts: boolean;
|
|
176
187
|
};
|
|
177
|
-
/**
|
|
178
|
-
* Opens a window with a transposed view of the grid
|
|
179
|
-
* it only works for client side data
|
|
180
|
-
*/
|
|
181
|
-
showTransposePopup(config: {
|
|
182
|
-
transposedColumnId: string;
|
|
183
|
-
hideTransposedColumn?: boolean;
|
|
184
|
-
}): void;
|
|
185
188
|
}
|
package/src/Api/ScopeApi.d.ts
CHANGED
|
@@ -31,6 +31,11 @@ export interface ScopeApi {
|
|
|
31
31
|
* @param scope Scope to check
|
|
32
32
|
*/
|
|
33
33
|
scopeHasDataType(scope: AdaptableScope): boolean;
|
|
34
|
+
/**
|
|
35
|
+
* True if Scope contains ColumnTypes
|
|
36
|
+
* @param scope Scope to check
|
|
37
|
+
*/
|
|
38
|
+
scopeHasColumnType(scope: AdaptableScope): boolean;
|
|
34
39
|
/**
|
|
35
40
|
* True if the Scope is DataTypes and contains only Boolean
|
|
36
41
|
* @param scope Scope to check
|
|
@@ -87,6 +92,11 @@ export interface ScopeApi {
|
|
|
87
92
|
* @param scope Scope to check
|
|
88
93
|
*/
|
|
89
94
|
getColumnIdsInScope(scope: AdaptableScope): string[] | undefined;
|
|
95
|
+
/**
|
|
96
|
+
* Returns all the ColumnTypes in the Scope
|
|
97
|
+
* @param scope Scope to check
|
|
98
|
+
*/
|
|
99
|
+
getColumnTypesInScope(scope: AdaptableScope): string[] | undefined;
|
|
90
100
|
/**
|
|
91
101
|
* Returns all the DataTypes in the Scope
|
|
92
102
|
* @param scope Scope to check
|
|
@@ -19,6 +19,10 @@ export interface AdaptableColumnBase extends AdaptableObject {
|
|
|
19
19
|
* DataType of the Column
|
|
20
20
|
*/
|
|
21
21
|
dataType: AdaptableColumnDataType;
|
|
22
|
+
/**
|
|
23
|
+
* Column Types of the Column
|
|
24
|
+
*/
|
|
25
|
+
columnTypes?: string[];
|
|
22
26
|
}
|
|
23
27
|
export declare const isValidOrderForColumnGroups: ({ oldColumns, newColumns, }: {
|
|
24
28
|
oldColumns: AdaptableColumn[];
|
|
@@ -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' | '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' | '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' | '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';
|
|
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' | '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' | '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' | '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' | 'rows';
|
|
@@ -8,7 +8,10 @@ export type ScopeDataTypes<Type = ScopeDataType> = {
|
|
|
8
8
|
export type ScopeColumnIds = {
|
|
9
9
|
ColumnIds: string[];
|
|
10
10
|
};
|
|
11
|
+
export type ScopeColumnTypes = {
|
|
12
|
+
ColumnTypes: string[];
|
|
13
|
+
};
|
|
11
14
|
/**
|
|
12
15
|
* Defines where a given Object / Module is active
|
|
13
16
|
*/
|
|
14
|
-
export type AdaptableScope<Type = ScopeDataType> = ScopeAll | ScopeDataTypes<Type> | ScopeColumnIds;
|
|
17
|
+
export type AdaptableScope<Type = ScopeDataType> = ScopeAll | ScopeDataTypes<Type> | ScopeColumnIds | ScopeColumnTypes;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { SummarySupportedExpression } from '../../Utilities/Services/SummaryService';
|
|
2
|
+
export declare const ROW_SUMMARY_ROW_ID = "__ROW_SUMMARY_ROW_ID";
|
|
3
|
+
export type RowSummaryPosition = 'Top' | 'Bottom';
|
|
4
|
+
export interface RowSummary {
|
|
5
|
+
Position?: RowSummaryPosition;
|
|
6
|
+
ColumnsMap: Record<string, SummarySupportedExpression>;
|
|
7
|
+
}
|
|
@@ -3,6 +3,7 @@ import { AdaptableObject } from './Common/AdaptableObject';
|
|
|
3
3
|
import { ColumnSort } from './Common/ColumnSort';
|
|
4
4
|
import { ColumnFilter, GridFilter } from '../types';
|
|
5
5
|
import { AggregationColumns } from './Common/AggregationColumns';
|
|
6
|
+
import { RowSummary } from './Common/RowSummary';
|
|
6
7
|
/**
|
|
7
8
|
* Predefined Configuration for the Layout Module
|
|
8
9
|
*/
|
|
@@ -82,4 +83,8 @@ export interface Layout extends AdaptableObject {
|
|
|
82
83
|
* Whether to include the aggFunc name in the column header: e.g. 'sum(Bank Balance)' will just be 'Bank Balance'
|
|
83
84
|
*/
|
|
84
85
|
SuppressAggFuncInHeader?: boolean;
|
|
86
|
+
/**
|
|
87
|
+
* Row summaries
|
|
88
|
+
*/
|
|
89
|
+
RowSummaries?: RowSummary[];
|
|
85
90
|
}
|
|
@@ -20,6 +20,10 @@ export type { OpenFinReport };
|
|
|
20
20
|
type ROW_PRIMARY_KEY = string;
|
|
21
21
|
type COLUMN_ID_OR_WHOLE_ROW_LABEL = string;
|
|
22
22
|
export type DataChangeHistoryMode = 'ACTIVE' | 'INACTIVE' | 'SUSPENDED';
|
|
23
|
+
export type SystemRowSummary = {
|
|
24
|
+
Position: 'Top' | 'Bottom';
|
|
25
|
+
RowData: Record<string, any>;
|
|
26
|
+
};
|
|
23
27
|
/**
|
|
24
28
|
* Internal state, used by Adaptable during a session; none of it is provided through Predefined Config, nor is it persisted
|
|
25
29
|
*/
|
|
@@ -103,6 +107,9 @@ export interface SystemState extends InternalState, IPushPullState, OpenFinState
|
|
|
103
107
|
focusedEntity?: 'Note' | 'Comment';
|
|
104
108
|
popupPosition?: CellAddress | null;
|
|
105
109
|
};
|
|
110
|
+
RowSummary?: {
|
|
111
|
+
rowSummaries?: SystemRowSummary[];
|
|
112
|
+
};
|
|
106
113
|
}
|
|
107
114
|
export interface ProgressIndicator {
|
|
108
115
|
active: boolean;
|
|
@@ -30,6 +30,10 @@ export declare const LAYOUT_SELECT = "LAYOUT_SELECT";
|
|
|
30
30
|
* @ReduxAction A Layout has been (auto)saved
|
|
31
31
|
*/
|
|
32
32
|
export declare const LAYOUT_SAVE = "LAYOUT_SAVE";
|
|
33
|
+
/**
|
|
34
|
+
* @ReduxAction A Column has been added
|
|
35
|
+
*/
|
|
36
|
+
export declare const LAYOUT_ADD_COLUMN = "LAYOUT_ADD_COLUMN";
|
|
33
37
|
/**
|
|
34
38
|
* @ReduxAction A Column has been removed
|
|
35
39
|
*/
|
|
@@ -145,6 +149,10 @@ export interface LayoutSetColumnCaptionAction extends Redux.Action {
|
|
|
145
149
|
columnId: string;
|
|
146
150
|
caption: string;
|
|
147
151
|
}
|
|
152
|
+
export interface LayoutAddColumnAction extends Redux.Action {
|
|
153
|
+
layoutName: string;
|
|
154
|
+
columnId: string;
|
|
155
|
+
}
|
|
148
156
|
export interface LayoutRemoveColumnAction extends Redux.Action {
|
|
149
157
|
layoutName: string;
|
|
150
158
|
columnId: string;
|
|
@@ -163,6 +171,7 @@ export declare const LayoutAdd: (layout: Layout) => LayoutAddAction;
|
|
|
163
171
|
export declare const LayoutDelete: (layout: Layout) => LayoutDeleteAction;
|
|
164
172
|
export declare const LayoutSave: (layout: Layout) => LayoutSaveAction;
|
|
165
173
|
export declare const LayoutSetColumnCaption: (layoutName: string, columnId: string, caption: string) => LayoutSetColumnCaptionAction;
|
|
174
|
+
export declare const LayoutAddColumn: (layoutName: string, columnId: string) => LayoutAddColumnAction;
|
|
166
175
|
export declare const LayoutRemoveColumn: (layoutName: string, columnId: string) => LayoutRemoveColumnAction;
|
|
167
176
|
export declare const LayoutSelect: (layoutName: string) => LayoutSelectAction;
|
|
168
177
|
export declare const LayoutReady: (layoutState: LayoutState) => LayoutReadyAction;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.LayoutReducer = exports.getColumnFilterSelector = exports.LayoutReady = exports.LayoutSelect = exports.LayoutRemoveColumn = exports.LayoutSetColumnCaption = exports.LayoutSave = exports.LayoutDelete = exports.LayoutAdd = exports.LayoutGridFilterClear = exports.LayoutGridFilterUnSuspend = exports.LayoutGridFilterSuspend = exports.LayoutGridFilterSet = exports.LayoutColumnFilterUnSuspendAll = exports.LayoutColumnFilterSuspendAll = exports.LayoutColumnFilterUnSuspend = exports.LayoutColumnFilterSuspend = exports.LayoutColumnFilterClear = exports.LayoutColumnFilterClearAll = exports.LayoutColumnFilterSet = exports.LayoutColumnFilterEdit = exports.LayoutColumnFilterAdd = exports.LAYOUT_GRID_FILTER_CLEAR = exports.LAYOUT_GRID_FILTER_SET = exports.LAYOUT_GRID_FILTER_UNSUSPEND = exports.LAYOUT_GRID_FILTER_SUSPEND = exports.LAYOUT_COLUMN_FILTER_UNSUSPEND_ALL = exports.LAYOUT_COLUMN_FILTER_SUSPEND_ALL = exports.LAYOUT_COLUMN_FILTER_UNSUSPEND = exports.LAYOUT_COLUMN_FILTER_SUSPEND = exports.LAYOUT_COLUMN_FILTER_CLEAR = exports.LAYOUT_COLUMN_FILTER_CLEAR_ALL = exports.LAYOUT_COLUMN_FILTER_SET = exports.LAYOUT_COLUMN_FILTER_EDIT = exports.LAYOUT_COLUMN_FILTER_ADD = exports.LAYOUT_REMOVE_COLUMN = exports.LAYOUT_SAVE = exports.LAYOUT_SELECT = exports.LAYOUT_DELETE = exports.LAYOUT_EDIT = exports.LAYOUT_ADD = exports.LAYOUT_READY = exports.LAYOUT_SET_COLUMN_CAPTION = void 0;
|
|
3
|
+
exports.LayoutReducer = exports.getColumnFilterSelector = exports.LayoutReady = exports.LayoutSelect = exports.LayoutRemoveColumn = exports.LayoutAddColumn = exports.LayoutSetColumnCaption = exports.LayoutSave = exports.LayoutDelete = exports.LayoutAdd = exports.LayoutGridFilterClear = exports.LayoutGridFilterUnSuspend = exports.LayoutGridFilterSuspend = exports.LayoutGridFilterSet = exports.LayoutColumnFilterUnSuspendAll = exports.LayoutColumnFilterSuspendAll = exports.LayoutColumnFilterUnSuspend = exports.LayoutColumnFilterSuspend = exports.LayoutColumnFilterClear = exports.LayoutColumnFilterClearAll = exports.LayoutColumnFilterSet = exports.LayoutColumnFilterEdit = exports.LayoutColumnFilterAdd = exports.LAYOUT_GRID_FILTER_CLEAR = exports.LAYOUT_GRID_FILTER_SET = exports.LAYOUT_GRID_FILTER_UNSUSPEND = exports.LAYOUT_GRID_FILTER_SUSPEND = exports.LAYOUT_COLUMN_FILTER_UNSUSPEND_ALL = exports.LAYOUT_COLUMN_FILTER_SUSPEND_ALL = exports.LAYOUT_COLUMN_FILTER_UNSUSPEND = exports.LAYOUT_COLUMN_FILTER_SUSPEND = exports.LAYOUT_COLUMN_FILTER_CLEAR = exports.LAYOUT_COLUMN_FILTER_CLEAR_ALL = exports.LAYOUT_COLUMN_FILTER_SET = exports.LAYOUT_COLUMN_FILTER_EDIT = exports.LAYOUT_COLUMN_FILTER_ADD = exports.LAYOUT_REMOVE_COLUMN = exports.LAYOUT_ADD_COLUMN = exports.LAYOUT_SAVE = exports.LAYOUT_SELECT = exports.LAYOUT_DELETE = exports.LAYOUT_EDIT = exports.LAYOUT_ADD = exports.LAYOUT_READY = exports.LAYOUT_SET_COLUMN_CAPTION = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const GeneralConstants_1 = require("../../Utilities/Constants/GeneralConstants");
|
|
6
6
|
const AdaptableHelper_1 = tslib_1.__importDefault(require("../../Utilities/Helpers/AdaptableHelper"));
|
|
@@ -32,6 +32,10 @@ exports.LAYOUT_SELECT = 'LAYOUT_SELECT';
|
|
|
32
32
|
* @ReduxAction A Layout has been (auto)saved
|
|
33
33
|
*/
|
|
34
34
|
exports.LAYOUT_SAVE = 'LAYOUT_SAVE';
|
|
35
|
+
/**
|
|
36
|
+
* @ReduxAction A Column has been added
|
|
37
|
+
*/
|
|
38
|
+
exports.LAYOUT_ADD_COLUMN = 'LAYOUT_ADD_COLUMN';
|
|
35
39
|
/**
|
|
36
40
|
* @ReduxAction A Column has been removed
|
|
37
41
|
*/
|
|
@@ -170,6 +174,12 @@ const LayoutSetColumnCaption = (layoutName, columnId, caption) => ({
|
|
|
170
174
|
caption,
|
|
171
175
|
});
|
|
172
176
|
exports.LayoutSetColumnCaption = LayoutSetColumnCaption;
|
|
177
|
+
const LayoutAddColumn = (layoutName, columnId) => ({
|
|
178
|
+
type: exports.LAYOUT_ADD_COLUMN,
|
|
179
|
+
layoutName,
|
|
180
|
+
columnId,
|
|
181
|
+
});
|
|
182
|
+
exports.LayoutAddColumn = LayoutAddColumn;
|
|
173
183
|
const LayoutRemoveColumn = (layoutName, columnId) => ({
|
|
174
184
|
type: exports.LAYOUT_REMOVE_COLUMN,
|
|
175
185
|
layoutName,
|
|
@@ -243,6 +253,17 @@ const LayoutReducer = (state = initialState, action) => {
|
|
|
243
253
|
}
|
|
244
254
|
return state;
|
|
245
255
|
}
|
|
256
|
+
case exports.LAYOUT_ADD_COLUMN: {
|
|
257
|
+
const addColumnAction = action;
|
|
258
|
+
const layoutname = addColumnAction.layoutName;
|
|
259
|
+
const colToAdd = addColumnAction.columnId;
|
|
260
|
+
let layoutToUpdate = state.Layouts.find((l) => l.Name === layoutname);
|
|
261
|
+
if (layoutToUpdate) {
|
|
262
|
+
layoutToUpdate.Columns.push(colToAdd);
|
|
263
|
+
return Object.assign(Object.assign({}, state), { Layouts: state.Layouts.map((abObject) => abObject.Uuid === layoutToUpdate.Uuid ? layoutToUpdate : abObject) });
|
|
264
|
+
}
|
|
265
|
+
return state;
|
|
266
|
+
}
|
|
246
267
|
case exports.LAYOUT_REMOVE_COLUMN: {
|
|
247
268
|
const removeColumnAction = action;
|
|
248
269
|
const layoutname = removeColumnAction.layoutName;
|
|
@@ -77,6 +77,7 @@ export declare const SYSTEM_VISUAL_EXPORT_END = "SYSTEM_VISUAL_EXPORT_END";
|
|
|
77
77
|
export declare const SYSTEM_CELL_POPUP_SHOW = "SYSTEM_CELL_POPUP_SHOW";
|
|
78
78
|
export declare const SYSTEM_CELL_POPUP_HIDE = "SYSTEM_CELL_POPUP_HIDE";
|
|
79
79
|
export declare const SYSTEM_CELL_POPUP_EDIT_FOCUSED_ENTITY = "SYSTEM_CELL_POPUP_EDIT_FOCUSED_ENTITY";
|
|
80
|
+
export declare const SYSTEM_SUMMARY_ROW_SET = "SYSTEM_SUMMARY_ROW_SET";
|
|
80
81
|
export declare const DATA_IMPORT_COMPLETED = "DATA_IMPORT_COMPLETED";
|
|
81
82
|
export interface DataImportCompletedAction extends Redux.Action {
|
|
82
83
|
dataImportedInfo: DataImportedInfo;
|
|
@@ -328,6 +329,10 @@ export declare const SystemVisualExportEnd: () => SystemVisualExportEndAction;
|
|
|
328
329
|
export declare const SystemQuickSearchFloatingVisibility: (visible: boolean) => SystemQuickSearchFloatingVisibilityAction;
|
|
329
330
|
export declare const SystemCellPopupShow: (cellPosition: CellAddress, editMode?: boolean) => SystemCellPopupShowAction;
|
|
330
331
|
export declare const SystemCellPopupEditFocusedEntity: (focusedEntity: 'Note' | 'Comment') => SystemCellPopupEditFocusedEntityAction;
|
|
332
|
+
export declare const SystemRowSummartSet: (systemRowSummaries: SystemState['RowSummary']['rowSummaries']) => {
|
|
333
|
+
readonly type: "SYSTEM_SUMMARY_ROW_SET";
|
|
334
|
+
readonly rowSummaries: import("../../PredefinedConfig/SystemState").SystemRowSummary[];
|
|
335
|
+
};
|
|
331
336
|
export declare const SystemCellPopupHide: () => SystemCellPopupHideAction;
|
|
332
337
|
export declare const SystemDisableDeleteConfirmationSelector: (state: SystemState) => boolean;
|
|
333
338
|
export declare const SystemPreviousGroupedColumnsSelector: (state: SystemState) => Record<string, Record<string, number>>;
|