@adaptabletools/adaptable-cjs 18.0.0-canary.26 → 18.0.0-canary.28
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/AdaptableOptions/MenuOptions.d.ts +7 -19
- package/src/AdaptableOptions/MenuOptions.js +0 -98
- package/src/Api/Implementation/ColumnApiImpl.js +6 -6
- package/src/Api/Implementation/ExpressionApiImpl.js +12 -12
- package/src/Api/Implementation/GridApiImpl.js +2 -2
- package/src/Api/Implementation/LayoutApiImpl.d.ts +0 -9
- package/src/Api/Implementation/LayoutApiImpl.js +0 -4
- package/src/Api/Implementation/ScopeApiImpl.js +4 -4
- package/src/Api/Internal/ColumnFilterInternalApi.js +2 -2
- package/src/Api/Internal/CommentsInternalApi.d.ts +1 -1
- package/src/Api/Internal/CommentsInternalApi.js +1 -1
- package/src/Api/Internal/DashboardInternalApi.js +2 -2
- package/src/Api/Internal/FormatColumnInternalApi.js +5 -3
- package/src/Api/Internal/GridFilterInternalApi.d.ts +2 -2
- package/src/Api/Internal/GridFilterInternalApi.js +2 -2
- package/src/Api/Internal/NoteInternalApi.d.ts +1 -1
- package/src/Api/Internal/NoteInternalApi.js +1 -1
- package/src/Api/LayoutApi.d.ts +0 -12
- package/src/PredefinedConfig/Common/AdaptableIcon.d.ts +1 -1
- package/src/PredefinedConfig/Common/Fdc3Intent.d.ts +2 -2
- package/src/PredefinedConfig/Common/Menu.d.ts +2 -2
- package/src/PredefinedConfig/Common/Menu.js +22 -20
- package/src/PredefinedConfig/Common/TransposeConfig.d.ts +3 -3
- package/src/Strategy/AdaptableModuleBase.d.ts +3 -4
- package/src/Strategy/AdaptableModuleBase.js +5 -9
- package/src/Strategy/AlertModule.d.ts +1 -1
- package/src/Strategy/AlertModule.js +1 -1
- package/src/Strategy/BulkUpdateModule.d.ts +1 -1
- package/src/Strategy/BulkUpdateModule.js +3 -2
- package/src/Strategy/CalculatedColumnModule.d.ts +2 -2
- package/src/Strategy/CalculatedColumnModule.js +2 -2
- package/src/Strategy/CellSummaryModule.d.ts +2 -2
- package/src/Strategy/CellSummaryModule.js +2 -2
- package/src/Strategy/ColumnFilterModule.d.ts +2 -2
- package/src/Strategy/ColumnFilterModule.js +17 -42
- package/src/Strategy/ColumnInfoModule.d.ts +2 -2
- package/src/Strategy/ColumnInfoModule.js +4 -4
- package/src/Strategy/CommentModule.d.ts +1 -2
- package/src/Strategy/CommentModule.js +29 -30
- package/src/Strategy/CustomSortModule.d.ts +1 -1
- package/src/Strategy/CustomSortModule.js +1 -1
- package/src/Strategy/DashboardModule.d.ts +2 -2
- package/src/Strategy/DashboardModule.js +3 -14
- package/src/Strategy/DataImportModule.d.ts +3 -3
- package/src/Strategy/DataImportModule.js +3 -3
- package/src/Strategy/ExportModule.d.ts +1 -2
- package/src/Strategy/ExportModule.js +12 -41
- package/src/Strategy/Fdc3Module.d.ts +1 -1
- package/src/Strategy/Fdc3Module.js +1 -14
- package/src/Strategy/FlashingCellModule.d.ts +2 -2
- package/src/Strategy/FlashingCellModule.js +2 -2
- package/src/Strategy/FormatColumnModule.d.ts +1 -1
- package/src/Strategy/FormatColumnModule.js +28 -47
- package/src/Strategy/FreeTextColumnModule.d.ts +1 -1
- package/src/Strategy/FreeTextColumnModule.js +1 -1
- package/src/Strategy/GridInfoModule.d.ts +2 -2
- package/src/Strategy/GridInfoModule.js +3 -3
- package/src/Strategy/Interface/IModule.d.ts +3 -3
- package/src/Strategy/LayoutModule.d.ts +4 -4
- package/src/Strategy/LayoutModule.js +47 -72
- package/src/Strategy/NoteModule.d.ts +1 -2
- package/src/Strategy/NoteModule.js +28 -30
- package/src/Strategy/PlusMinusModule.d.ts +1 -1
- package/src/Strategy/PlusMinusModule.js +1 -1
- package/src/Strategy/SettingsPanelModule.d.ts +3 -3
- package/src/Strategy/SettingsPanelModule.js +3 -3
- package/src/Strategy/SmartEditModule.d.ts +1 -1
- package/src/Strategy/SmartEditModule.js +3 -2
- package/src/Strategy/StyledColumnModule.d.ts +1 -1
- package/src/Strategy/StyledColumnModule.js +17 -15
- package/src/Strategy/SystemStatusModule.d.ts +2 -2
- package/src/Strategy/SystemStatusModule.js +4 -3
- package/src/Utilities/ExpressionFunctions/aggregatedScalarExpressionFunctions.js +4 -2
- package/src/Utilities/Services/ModuleService.js +2 -2
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnWizard.d.ts +1 -1
- package/src/agGrid/AdaptableAgGrid.js +2 -1
- package/src/agGrid/AgGridColumnAdapter.js +2 -2
- package/src/agGrid/AgGridMenuAdapter.d.ts +19 -8
- package/src/agGrid/AgGridMenuAdapter.js +319 -50
- package/src/components/icons/filter-off.d.ts +3 -0
- package/src/components/icons/filter-off.js +7 -0
- package/src/components/icons/grid-info.d.ts +3 -0
- package/src/components/icons/grid-info.js +7 -0
- package/src/components/icons/index.js +10 -0
- package/src/components/icons/select-all.d.ts +3 -0
- package/src/components/icons/select-all.js +7 -0
- package/src/components/icons/select-fwd.d.ts +3 -0
- package/src/components/icons/select-fwd.js +7 -0
- package/src/components/icons/select-off.d.ts +3 -0
- package/src/components/icons/select-off.js +7 -0
- package/src/env.js +2 -2
- package/src/metamodel/adaptable.metamodel.js +1 -1
- package/src/parser/src/parser.js +1218 -55
- package/src/parser/src/predicate/mapQlPredicateToExpression.js +1 -3
- package/src/parser/src/types.js +1 -2
- package/tsconfig.cjs.tsbuildinfo +1 -1
|
@@ -6,7 +6,7 @@ import { AccessLevel, AdaptableApi } from '../types';
|
|
|
6
6
|
export declare class BulkUpdateModule extends AdaptableModuleBase implements IBulkUpdateModule {
|
|
7
7
|
constructor(api: AdaptableApi);
|
|
8
8
|
getViewAccessLevel(): AccessLevel;
|
|
9
|
-
|
|
9
|
+
createContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
10
10
|
checkCorrectCellSelection(): BulkUpdateValidationResult;
|
|
11
11
|
buildPreviewValues(bulkUpdateValue: any): PreviewInfo;
|
|
12
12
|
}
|
|
@@ -15,7 +15,7 @@ class BulkUpdateModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
15
15
|
getViewAccessLevel() {
|
|
16
16
|
return 'Full';
|
|
17
17
|
}
|
|
18
|
-
|
|
18
|
+
createContextMenuItems(menuContext) {
|
|
19
19
|
let menuItemShowPopup = undefined;
|
|
20
20
|
if (!menuContext.isRowGroupColumn && this.isModuleEditable()) {
|
|
21
21
|
if (menuContext.adaptableColumn &&
|
|
@@ -26,7 +26,8 @@ class BulkUpdateModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
26
26
|
let popUpParams = {
|
|
27
27
|
source: 'ContextMenu',
|
|
28
28
|
};
|
|
29
|
-
menuItemShowPopup = this.createMainMenuItemShowPopup({
|
|
29
|
+
menuItemShowPopup = this.createMainMenuItemShowPopup({
|
|
30
|
+
Name: 'bulk-update-apply',
|
|
30
31
|
Label: 'Apply Bulk Update',
|
|
31
32
|
ComponentName: this.moduleInfo.Popup,
|
|
32
33
|
Icon: this.moduleInfo.Glyph,
|
|
@@ -16,8 +16,8 @@ export declare class CalculatedColumnModule extends AdaptableModuleBase implemen
|
|
|
16
16
|
getExplicitlyReferencedColumnIds(calculatedColumn: CalculatedColumn): string[];
|
|
17
17
|
getReferencedNamedQueryNames(calculatedColumn: CalculatedColumn): string[];
|
|
18
18
|
private isCalculatedColumn;
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
createColumnMenuItems(column: AdaptableColumn): AdaptableMenuItem[] | undefined;
|
|
20
|
+
createContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
21
21
|
createEditCalculatedColumnMenuItem(column: AdaptableColumn): AdaptableMenuItem[];
|
|
22
22
|
getTeamSharingAction(): TeamSharingImportInfo<CalculatedColumn>;
|
|
23
23
|
toView(calculateColumn: CalculatedColumn): {
|
|
@@ -38,12 +38,12 @@ class CalculatedColumnModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
38
38
|
.getCalculatedColumns()
|
|
39
39
|
.find((cc) => cc.ColumnId == column.columnId)));
|
|
40
40
|
}
|
|
41
|
-
|
|
41
|
+
createColumnMenuItems(column) {
|
|
42
42
|
if (this.isModuleEditable() && this.isCalculatedColumn(column)) {
|
|
43
43
|
return this.createEditCalculatedColumnMenuItem(column);
|
|
44
44
|
}
|
|
45
45
|
}
|
|
46
|
-
|
|
46
|
+
createContextMenuItems(menuContext) {
|
|
47
47
|
if (!this.isModuleAvailable()) {
|
|
48
48
|
return;
|
|
49
49
|
}
|
|
@@ -11,8 +11,8 @@ export declare class CellSummaryModule extends AdaptableModuleBase implements IC
|
|
|
11
11
|
cachedCellSummary: WeakMap<SelectedCellInfo<any>, CellSummmary>;
|
|
12
12
|
constructor(api: AdaptableApi);
|
|
13
13
|
getViewAccessLevel(): AccessLevel;
|
|
14
|
-
|
|
15
|
-
|
|
14
|
+
createColumnMenuItems(column: AdaptableColumn): AdaptableMenuItem[] | undefined;
|
|
15
|
+
createContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
16
16
|
private createCellSummaryMenuItem;
|
|
17
17
|
createCellSummary(selectedCellInfo: SelectedCellInfo): CellSummmary;
|
|
18
18
|
private getWeightedAverageCellSummary;
|
|
@@ -17,7 +17,7 @@ class CellSummaryModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
17
17
|
getViewAccessLevel() {
|
|
18
18
|
return 'Full';
|
|
19
19
|
}
|
|
20
|
-
|
|
20
|
+
createColumnMenuItems(column) {
|
|
21
21
|
if (!this.isModuleAvailable()) {
|
|
22
22
|
return;
|
|
23
23
|
}
|
|
@@ -28,7 +28,7 @@ class CellSummaryModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
28
28
|
}),
|
|
29
29
|
];
|
|
30
30
|
}
|
|
31
|
-
|
|
31
|
+
createContextMenuItems(menuContext) {
|
|
32
32
|
if (!this.isModuleAvailable()) {
|
|
33
33
|
return;
|
|
34
34
|
}
|
|
@@ -13,8 +13,8 @@ export declare class ColumnFilterModule extends AdaptableModuleBase implements I
|
|
|
13
13
|
getExplicitlyReferencedColumnIds(columnFilter: ColumnFilter): string[];
|
|
14
14
|
hasNamedQueryReferences(): boolean;
|
|
15
15
|
onAdaptableReady(): void;
|
|
16
|
-
|
|
17
|
-
|
|
16
|
+
createColumnMenuItems(column: AdaptableColumn): AdaptableMenuItem[] | undefined;
|
|
17
|
+
createContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
18
18
|
private getExistingColumnFilter;
|
|
19
19
|
getTeamSharingAction(): TeamSharingImportInfo<ColumnFilter>;
|
|
20
20
|
toViewCompact(filter: ColumnFilter): AdaptableObjectCompactView;
|
|
@@ -4,7 +4,6 @@ exports.ColumnFilterModule = void 0;
|
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const AdaptableModuleBase_1 = require("./AdaptableModuleBase");
|
|
6
6
|
const ModuleConstants = tslib_1.__importStar(require("../Utilities/Constants/ModuleConstants"));
|
|
7
|
-
const ArrayExtensions_1 = tslib_1.__importDefault(require("../Utilities/Extensions/ArrayExtensions"));
|
|
8
7
|
const LayoutRedux = tslib_1.__importStar(require("../Redux/ActionsReducers/LayoutRedux"));
|
|
9
8
|
const SystemRedux = tslib_1.__importStar(require("../Redux/ActionsReducers/SystemRedux"));
|
|
10
9
|
const FilterStatusBarSubPanelPopover_1 = require("../View/Filter/FilterStatusBarSubPanelPopover");
|
|
@@ -43,8 +42,8 @@ class ColumnFilterModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
43
42
|
}
|
|
44
43
|
});
|
|
45
44
|
}
|
|
46
|
-
|
|
47
|
-
let
|
|
45
|
+
createColumnMenuItems(column) {
|
|
46
|
+
let columnFilterMenuItems = [];
|
|
48
47
|
if (column &&
|
|
49
48
|
column.filterable &&
|
|
50
49
|
this.api.optionsApi.getColumnFilterOptions().useAdaptableColumnFiltering) {
|
|
@@ -52,35 +51,22 @@ class ColumnFilterModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
52
51
|
const isFilterVisible = this.api.columnFilterApi.isQuickFilterVisible();
|
|
53
52
|
if (this.isModuleEditable() &&
|
|
54
53
|
this.api.optionsApi.getColumnFilterOptions().useAdaptableColumnFiltering) {
|
|
55
|
-
|
|
54
|
+
columnFilterMenuItems.push(this.createMenuItemReduxAction(isFilterVisible ? 'column-filter-bar-hide' : 'column-filter-bar-show', isFilterVisible ? 'Hide Filter Bar' : 'Show Filter Bar', isFilterVisible ? 'filter-off' : 'filter', isFilterVisible
|
|
56
55
|
? SystemRedux.SystemQuickFilterBarHide()
|
|
57
56
|
: SystemRedux.SystemQuickFilterBarShow()));
|
|
58
57
|
}
|
|
59
58
|
}
|
|
60
59
|
const existingColumnFilter = this.getExistingColumnFilter(column);
|
|
61
60
|
if (existingColumnFilter) {
|
|
62
|
-
|
|
63
|
-
|
|
61
|
+
columnFilterMenuItems.push(this.createMenuItemReduxAction('column-filter-clear', 'Clear Filter', 'close', LayoutRedux.LayoutColumnFilterClear(existingColumnFilter)));
|
|
62
|
+
columnFilterMenuItems.push(this.createMenuItemReduxAction(existingColumnFilter.IsSuspended ? 'column-filter-unsuspend' : 'column-filter-suspend', existingColumnFilter.IsSuspended ? 'Unsuspend Filter' : 'Suspend Filter', existingColumnFilter.IsSuspended ? 'resume' : 'pause', existingColumnFilter.IsSuspended
|
|
64
63
|
? LayoutRedux.LayoutColumnFilterUnSuspend(existingColumnFilter)
|
|
65
64
|
: LayoutRedux.LayoutColumnFilterSuspend(existingColumnFilter)));
|
|
66
65
|
}
|
|
67
|
-
|
|
68
|
-
return [
|
|
69
|
-
{
|
|
70
|
-
name: 'column-filter-parent',
|
|
71
|
-
label: this.moduleInfo.FriendlyName,
|
|
72
|
-
isVisible: true,
|
|
73
|
-
module: this.moduleInfo.ModuleName,
|
|
74
|
-
icon: {
|
|
75
|
-
name: this.moduleInfo.Glyph,
|
|
76
|
-
},
|
|
77
|
-
subItems: filterSubMenuItems,
|
|
78
|
-
},
|
|
79
|
-
];
|
|
80
|
-
}
|
|
66
|
+
return columnFilterMenuItems;
|
|
81
67
|
}
|
|
82
68
|
}
|
|
83
|
-
|
|
69
|
+
createContextMenuItems(menuContext) {
|
|
84
70
|
if (!menuContext.isRowGroupColumn && this.isModuleAvailable()) {
|
|
85
71
|
if (menuContext.adaptableColumn &&
|
|
86
72
|
menuContext.adaptableColumn.filterable &&
|
|
@@ -102,28 +88,17 @@ class ColumnFilterModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
102
88
|
];
|
|
103
89
|
}
|
|
104
90
|
else {
|
|
105
|
-
let filterSubMenuItems = [];
|
|
106
|
-
filterSubMenuItems.push(this.createMenuItemReduxAction('column-filter-clear', 'Clear Filter', 'close', LayoutRedux.LayoutColumnFilterClear(existingColumnFilter)));
|
|
107
|
-
filterSubMenuItems.push(this.createMenuItemClickFunction(existingColumnFilter.IsSuspended
|
|
108
|
-
? 'column-filter-unsuspend'
|
|
109
|
-
: 'column-filter-suspend', existingColumnFilter.IsSuspended ? 'Unsuspend Filter' : 'Suspend Filter', existingColumnFilter.IsSuspended ? 'resume' : 'pause', existingColumnFilter.IsSuspended
|
|
110
|
-
? () => {
|
|
111
|
-
this.api.columnFilterApi.unSuspendColumnFilter(existingColumnFilter);
|
|
112
|
-
}
|
|
113
|
-
: () => {
|
|
114
|
-
this.api.columnFilterApi.suspendColumnFilter(existingColumnFilter);
|
|
115
|
-
}));
|
|
116
91
|
return [
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
92
|
+
this.createMenuItemReduxAction('column-filter-clear', 'Clear Filter', 'close', LayoutRedux.LayoutColumnFilterClear(existingColumnFilter)),
|
|
93
|
+
this.createMenuItemClickFunction(existingColumnFilter.IsSuspended
|
|
94
|
+
? 'column-filter-unsuspend'
|
|
95
|
+
: 'column-filter-suspend', existingColumnFilter.IsSuspended ? 'Unsuspend Filter' : 'Suspend Filter', existingColumnFilter.IsSuspended ? 'resume' : 'pause', existingColumnFilter.IsSuspended
|
|
96
|
+
? () => {
|
|
97
|
+
this.api.columnFilterApi.unSuspendColumnFilter(existingColumnFilter);
|
|
98
|
+
}
|
|
99
|
+
: () => {
|
|
100
|
+
this.api.columnFilterApi.suspendColumnFilter(existingColumnFilter);
|
|
101
|
+
}),
|
|
127
102
|
];
|
|
128
103
|
}
|
|
129
104
|
}
|
|
@@ -6,6 +6,6 @@ import { AdaptableColumn, AdaptableMenuItem, ContextMenuContext } from '../types
|
|
|
6
6
|
export declare class ColumnInfoModule extends AdaptableModuleBase implements IModule {
|
|
7
7
|
constructor(api: AdaptableApi);
|
|
8
8
|
getViewAccessLevel(): AccessLevel;
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
createColumnMenuItems(column: AdaptableColumn): AdaptableMenuItem[] | undefined;
|
|
10
|
+
createContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
11
11
|
}
|
|
@@ -11,7 +11,7 @@ class ColumnInfoModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
11
11
|
getViewAccessLevel() {
|
|
12
12
|
return 'Full';
|
|
13
13
|
}
|
|
14
|
-
|
|
14
|
+
createColumnMenuItems(column) {
|
|
15
15
|
if (this.isModuleAvailable()) {
|
|
16
16
|
const columnPopUpParams = {
|
|
17
17
|
source: 'ColumnMenu',
|
|
@@ -22,13 +22,13 @@ class ColumnInfoModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
22
22
|
Name: 'column-info-show',
|
|
23
23
|
Label: 'Column Info',
|
|
24
24
|
ComponentName: this.moduleInfo.Popup,
|
|
25
|
-
Icon:
|
|
25
|
+
Icon: 'info',
|
|
26
26
|
PopupParams: columnPopUpParams,
|
|
27
27
|
}),
|
|
28
28
|
];
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
|
-
|
|
31
|
+
createContextMenuItems(menuContext) {
|
|
32
32
|
if (this.isModuleAvailable()) {
|
|
33
33
|
const columnPopUpParams = {
|
|
34
34
|
source: 'ColumnMenu',
|
|
@@ -39,7 +39,7 @@ class ColumnInfoModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
39
39
|
Name: 'column-info-show',
|
|
40
40
|
Label: 'Column Info',
|
|
41
41
|
ComponentName: this.moduleInfo.Popup,
|
|
42
|
-
Icon:
|
|
42
|
+
Icon: 'info',
|
|
43
43
|
PopupParams: columnPopUpParams,
|
|
44
44
|
}),
|
|
45
45
|
];
|
|
@@ -7,6 +7,5 @@ export declare class CommentModule extends AdaptableModuleBase implements IModul
|
|
|
7
7
|
onAdaptableReady(): void;
|
|
8
8
|
isModuleAvailable(): boolean;
|
|
9
9
|
private loadComments;
|
|
10
|
-
|
|
11
|
-
private getAddRemoveCommentsMenuItems;
|
|
10
|
+
createContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
12
11
|
}
|
|
@@ -28,49 +28,48 @@ class CommentModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
28
28
|
.getCommentOptions()) === null || _a === void 0 ? void 0 : _a.loadCommentThreads) === null || _b === void 0 ? void 0 : _b.call(_a, (0, ObjectFactory_1.createBaseContext)(this.api)));
|
|
29
29
|
this.api.commentApi.setGridComments(commentThreads);
|
|
30
30
|
}
|
|
31
|
-
|
|
32
|
-
var _a, _b;
|
|
31
|
+
createContextMenuItems(menuContext) {
|
|
32
|
+
var _a, _b, _c, _d, _e;
|
|
33
33
|
if (!this.isModuleAvailable()) {
|
|
34
|
-
return
|
|
34
|
+
return;
|
|
35
35
|
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
if (!isCellCommentable ||
|
|
39
|
-
isCellCommentable(Object.assign({ gridCell: menuContext.gridCell }, (0, ObjectFactory_1.createBaseContext)(this.api)))) {
|
|
40
|
-
items.push(...this.getAddRemoveCommentsMenuItems(menuContext));
|
|
36
|
+
if (!this.api.commentApi.internalApi.areCommentsSupported()) {
|
|
37
|
+
return;
|
|
41
38
|
}
|
|
42
|
-
return items;
|
|
43
|
-
}
|
|
44
|
-
getAddRemoveCommentsMenuItems(menuContext) {
|
|
45
|
-
var _a;
|
|
46
39
|
const items = [];
|
|
47
|
-
|
|
48
|
-
|
|
40
|
+
const isCellCommentable = typeof ((_b = (_a = this.api.optionsApi) === null || _a === void 0 ? void 0 : _a.getCommentOptions()) === null || _b === void 0 ? void 0 : _b.isCellCommentable) === 'function'
|
|
41
|
+
? (_d = (_c = this.api.optionsApi) === null || _c === void 0 ? void 0 : _c.getCommentOptions()) === null || _d === void 0 ? void 0 : _d.isCellCommentable(Object.assign({ gridCell: menuContext.gridCell }, (0, ObjectFactory_1.createBaseContext)(this.api)))
|
|
42
|
+
: true;
|
|
43
|
+
if (!isCellCommentable) {
|
|
44
|
+
return;
|
|
49
45
|
}
|
|
50
46
|
const cellAddress = {
|
|
51
47
|
PrimaryKeyValue: menuContext.primaryKeyValue,
|
|
52
48
|
ColumnId: menuContext.adaptableColumn.columnId,
|
|
53
49
|
};
|
|
54
|
-
const cellComments = (
|
|
50
|
+
const cellComments = (_e = this.api.commentApi.getCommentThread(cellAddress)) === null || _e === void 0 ? void 0 : _e.Comments;
|
|
55
51
|
if (cellComments) {
|
|
56
|
-
|
|
57
|
-
this.
|
|
58
|
-
|
|
52
|
+
return [
|
|
53
|
+
this.createMenuItemClickFunction('comment-remove', 'Remove Comment', this.moduleInfo.Glyph, () => {
|
|
54
|
+
this.api.commentApi.deleteCommentThread(cellAddress);
|
|
55
|
+
}),
|
|
56
|
+
];
|
|
59
57
|
}
|
|
60
58
|
else {
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
59
|
+
return [
|
|
60
|
+
this.createMenuItemClickFunction('comment-add', 'Add Comment', this.moduleInfo.Glyph, () => {
|
|
61
|
+
// add an empty one
|
|
62
|
+
this.api.commentApi.addCommentThread(Object.assign(Object.assign({}, cellAddress), { Comments: [] }));
|
|
63
|
+
requestAnimationFrame(() => {
|
|
64
|
+
this.api.internalApi.getCellPopupService().showPopup({
|
|
65
|
+
PrimaryKeyValue: menuContext.primaryKeyValue,
|
|
66
|
+
ColumnId: menuContext.adaptableColumn.columnId,
|
|
67
|
+
}, true);
|
|
68
|
+
this.api.internalApi.getCellPopupService().editFocusedEntity('Comment');
|
|
69
|
+
});
|
|
70
|
+
}),
|
|
71
|
+
];
|
|
72
72
|
}
|
|
73
|
-
return items;
|
|
74
73
|
}
|
|
75
74
|
}
|
|
76
75
|
exports.CommentModule = CommentModule;
|
|
@@ -15,7 +15,7 @@ export declare class CustomSortModule extends AdaptableModuleBase implements IMo
|
|
|
15
15
|
}): AdaptableObject[];
|
|
16
16
|
getExplicitlyReferencedColumnIds(customSort: CustomSort): string[];
|
|
17
17
|
hasNamedQueryReferences(): boolean;
|
|
18
|
-
|
|
18
|
+
createColumnMenuItems(column: AdaptableColumn): AdaptableMenuItem[] | undefined;
|
|
19
19
|
getTeamSharingAction(): TeamSharingImportInfo<CustomSort>;
|
|
20
20
|
toView(customSort: CustomSort): AdaptableObjectView;
|
|
21
21
|
toViewAll(): AdaptableObjectView[];
|
|
@@ -22,7 +22,7 @@ class CustomSortModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
22
22
|
hasNamedQueryReferences() {
|
|
23
23
|
return false;
|
|
24
24
|
}
|
|
25
|
-
|
|
25
|
+
createColumnMenuItems(column) {
|
|
26
26
|
if (column && this.isModuleEditable() && column.sortable) {
|
|
27
27
|
let customSort = this.api.customSortApi
|
|
28
28
|
.getCustomSorts()
|
|
@@ -5,7 +5,7 @@ import { AdaptableApi } from '../Api/AdaptableApi';
|
|
|
5
5
|
export declare class DashboardModule extends AdaptableModuleBase implements IModule {
|
|
6
6
|
constructor(api: AdaptableApi);
|
|
7
7
|
onAdaptableReady(): void;
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
createColumnMenuItems(): AdaptableMenuItem[] | undefined;
|
|
9
|
+
createContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
10
10
|
private buildMenuItems;
|
|
11
11
|
}
|
|
@@ -21,10 +21,10 @@ class DashboardModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
21
21
|
this.api.dashboardApi.internalApi.fireDashboardChangedEvent('ADAPTABLE_READY', null, this.api.dashboardApi.getDashboardState());
|
|
22
22
|
}, 20);
|
|
23
23
|
}
|
|
24
|
-
|
|
24
|
+
createColumnMenuItems() {
|
|
25
25
|
return this.buildMenuItems();
|
|
26
26
|
}
|
|
27
|
-
|
|
27
|
+
createContextMenuItems(menuContext) {
|
|
28
28
|
return this.buildMenuItems();
|
|
29
29
|
}
|
|
30
30
|
buildMenuItems() {
|
|
@@ -51,18 +51,7 @@ class DashboardModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
51
51
|
else {
|
|
52
52
|
menuItems.push(this.createMenuItemReduxAction('dashboard-hide', 'Hide', 'visibility-off-bold', DashboardRedux.DashboardSetIsHidden(true)));
|
|
53
53
|
}
|
|
54
|
-
return
|
|
55
|
-
{
|
|
56
|
-
name: 'dashboard-parent',
|
|
57
|
-
label: this.moduleInfo.FriendlyName,
|
|
58
|
-
isVisible: true,
|
|
59
|
-
module: this.moduleInfo.ModuleName,
|
|
60
|
-
icon: {
|
|
61
|
-
name: 'dashboard',
|
|
62
|
-
},
|
|
63
|
-
subItems: menuItems,
|
|
64
|
-
},
|
|
65
|
-
];
|
|
54
|
+
return menuItems;
|
|
66
55
|
}
|
|
67
56
|
}
|
|
68
57
|
}
|
|
@@ -4,8 +4,8 @@ import { AdaptableModuleBase } from './AdaptableModuleBase';
|
|
|
4
4
|
import { IModule } from './Interface/IModule';
|
|
5
5
|
export declare class DataImportModule extends AdaptableModuleBase implements IModule {
|
|
6
6
|
constructor(api: AdaptableApi);
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
createModuleMenuItem(source: 'ModuleMenu' | 'ModuleButton'): AdaptableMenuItem | undefined;
|
|
8
|
+
createContextMenuItems(): AdaptableMenuItem[] | undefined;
|
|
9
|
+
createColumnMenuItems(): AdaptableMenuItem[] | undefined;
|
|
10
10
|
private createDataImportMenuItem;
|
|
11
11
|
}
|
|
@@ -8,18 +8,18 @@ class DataImportModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
8
8
|
constructor(api) {
|
|
9
9
|
super(ModuleConstants.DataImportModuleId, ModuleConstants.DataImportFriendyName, 'import', 'DataImportPopup', 'Import Data', api);
|
|
10
10
|
}
|
|
11
|
-
|
|
11
|
+
createModuleMenuItem(source) {
|
|
12
12
|
if (this.isModuleAvailable()) {
|
|
13
13
|
return this.createDataImportMenuItem(source);
|
|
14
14
|
}
|
|
15
15
|
}
|
|
16
|
-
|
|
16
|
+
createContextMenuItems() {
|
|
17
17
|
if (this.isModuleAvailable()) {
|
|
18
18
|
return [this.createDataImportMenuItem('ContextMenu')];
|
|
19
19
|
}
|
|
20
20
|
return undefined;
|
|
21
21
|
}
|
|
22
|
-
|
|
22
|
+
createColumnMenuItems() {
|
|
23
23
|
if (this.isModuleAvailable()) {
|
|
24
24
|
return [this.createDataImportMenuItem('ColumnMenu')];
|
|
25
25
|
}
|
|
@@ -12,9 +12,8 @@ export declare class ExportModule extends AdaptableModuleBase implements IExport
|
|
|
12
12
|
getModuleAdaptableObjects(): AdaptableObject[];
|
|
13
13
|
getExplicitlyReferencedColumnIds(report: Report): string[];
|
|
14
14
|
getReferencedNamedQueryNames(report: Report): string[];
|
|
15
|
-
|
|
15
|
+
createContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
16
16
|
private buildReportMenuItems;
|
|
17
|
-
private buildExportMenuItem;
|
|
18
17
|
private getMenuName;
|
|
19
18
|
export(report: Report, exportDestination: ExportDestination | string): Promise<void>;
|
|
20
19
|
private preProcessExport;
|
|
@@ -44,14 +44,12 @@ class ExportModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
44
44
|
}
|
|
45
45
|
return this.api.namedQueryApi.internalApi.getReferencedNamedQueryNames(report.Query.BooleanExpression);
|
|
46
46
|
}
|
|
47
|
-
|
|
47
|
+
createContextMenuItems(menuContext) {
|
|
48
48
|
const canExport = !menuContext.isRowGroupColumn && this.isModuleAvailable();
|
|
49
49
|
if (!canExport) {
|
|
50
50
|
return;
|
|
51
51
|
}
|
|
52
52
|
let returnMenuItems = [];
|
|
53
|
-
let selectedCellmenuItems = [];
|
|
54
|
-
let selectedRowmenuItems = [];
|
|
55
53
|
const canExportCells = menuContext.selectedCellInfo &&
|
|
56
54
|
ArrayExtensions_1.default.IsNotNullOrEmpty(menuContext.selectedCellInfo.columns) &&
|
|
57
55
|
ArrayExtensions_1.default.IsNotNullOrEmpty(menuContext.selectedCellInfo.gridCells);
|
|
@@ -62,63 +60,36 @@ class ExportModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
62
60
|
menuContext.isSelectedRow;
|
|
63
61
|
if (canExportCells) {
|
|
64
62
|
const selectedCellReport = this.api.exportApi.getReportByName(GeneralConstants_1.SELECTED_CELLS_REPORT);
|
|
65
|
-
|
|
63
|
+
returnMenuItems.push(...this.buildReportMenuItems(selectedCellReport, 'cells'));
|
|
66
64
|
}
|
|
67
65
|
if (canExportRows) {
|
|
68
66
|
const selectedRowReport = this.api.exportApi.getReportByName(GeneralConstants_1.SELECTED_ROWS_REPORT);
|
|
69
|
-
|
|
70
|
-
}
|
|
71
|
-
// if only selected cells then just do one level
|
|
72
|
-
if (canExportCells && !canExportRows) {
|
|
73
|
-
returnMenuItems.push(this.buildExportMenuItem('Export Selected Cells', selectedCellmenuItems));
|
|
74
|
-
// if only selected Rows then just do one level
|
|
75
|
-
}
|
|
76
|
-
else if (canExportRows && !canExportCells) {
|
|
77
|
-
returnMenuItems.push(this.buildExportMenuItem('Export Selected Rows', selectedRowmenuItems));
|
|
78
|
-
}
|
|
79
|
-
// if both selected Cells and Rows then add a new level
|
|
80
|
-
else if (canExportRows && canExportCells) {
|
|
81
|
-
const exportSelectedCellsMenuItem = this.buildExportMenuItem('Cells', selectedCellmenuItems);
|
|
82
|
-
const exportSelectedRowsMenuItem = this.buildExportMenuItem('Rows', selectedRowmenuItems);
|
|
83
|
-
returnMenuItems.push(this.buildExportMenuItem('Export Selected', [
|
|
84
|
-
exportSelectedCellsMenuItem,
|
|
85
|
-
exportSelectedRowsMenuItem,
|
|
86
|
-
]));
|
|
67
|
+
returnMenuItems.push(...this.buildReportMenuItems(selectedRowReport, 'rows'));
|
|
87
68
|
}
|
|
88
69
|
return returnMenuItems;
|
|
89
70
|
}
|
|
90
|
-
buildReportMenuItems(report) {
|
|
71
|
+
buildReportMenuItems(report, selectionType) {
|
|
91
72
|
const menuItems = [];
|
|
92
73
|
for (const destination of this.api.exportApi.getAvailableExportDestinations()) {
|
|
93
|
-
menuItems.push(this.createMenuItemClickFunction(this.getMenuName(destination), destination, this.moduleInfo.Glyph, () => this.export(report, destination)));
|
|
74
|
+
menuItems.push(this.createMenuItemClickFunction(this.getMenuName(destination, selectionType), destination, this.moduleInfo.Glyph, () => this.export(report, destination)));
|
|
94
75
|
}
|
|
95
76
|
for (const customDestination of this.api.exportApi.getCustomDestinations()) {
|
|
96
|
-
menuItems.push(this.createMenuItemClickFunction(
|
|
77
|
+
menuItems.push(this.createMenuItemClickFunction(`export-${selectionType}-custom-destination`, customDestination.name, this.moduleInfo.Glyph, () => this.export(report, customDestination.name)));
|
|
97
78
|
}
|
|
98
79
|
return menuItems;
|
|
99
80
|
}
|
|
100
|
-
|
|
101
|
-
return {
|
|
102
|
-
name: 'export-parent',
|
|
103
|
-
label: label,
|
|
104
|
-
module: this.moduleInfo.ModuleName,
|
|
105
|
-
isVisible: true,
|
|
106
|
-
icon: { name: this.moduleInfo.Glyph },
|
|
107
|
-
subItems: subItems,
|
|
108
|
-
};
|
|
109
|
-
}
|
|
110
|
-
getMenuName(exportDestination) {
|
|
81
|
+
getMenuName(exportDestination, selectionType) {
|
|
111
82
|
switch (exportDestination) {
|
|
112
83
|
case Enums_1.ExportDestination.CSV:
|
|
113
|
-
return
|
|
84
|
+
return `export-${selectionType}-csv`;
|
|
114
85
|
case Enums_1.ExportDestination.Clipboard:
|
|
115
|
-
return
|
|
86
|
+
return `export-${selectionType}-clipboard`;
|
|
116
87
|
case Enums_1.ExportDestination.Excel:
|
|
117
|
-
return
|
|
88
|
+
return `export-${selectionType}-excel`;
|
|
118
89
|
case Enums_1.ExportDestination.JSON:
|
|
119
|
-
return
|
|
90
|
+
return `export-${selectionType}-json`;
|
|
120
91
|
case Enums_1.ExportDestination.Table:
|
|
121
|
-
return
|
|
92
|
+
return `export-${selectionType}-table`;
|
|
122
93
|
}
|
|
123
94
|
}
|
|
124
95
|
async export(report, exportDestination) {
|
|
@@ -4,7 +4,7 @@ import { AdaptableApi } from '../Api/AdaptableApi';
|
|
|
4
4
|
import { AdaptableMenuItem, ContextMenuContext } from '../PredefinedConfig/Common/Menu';
|
|
5
5
|
export declare class Fdc3Module extends AdaptableModuleBase implements IModule {
|
|
6
6
|
constructor(api: AdaptableApi);
|
|
7
|
-
|
|
7
|
+
createContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
8
8
|
private buildRaiseIntentMenuItem;
|
|
9
9
|
private buildBroadcastMenuItem;
|
|
10
10
|
private getFdc3Api;
|
|
@@ -8,7 +8,7 @@ class Fdc3Module extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
8
8
|
constructor(api) {
|
|
9
9
|
super(ModuleConstants.Fdc3ModuleId, ModuleConstants.Fdc3FriendlyName, 'fdc3', null, 'The FDC3 Module - handles the FDC3 integration', api);
|
|
10
10
|
}
|
|
11
|
-
|
|
11
|
+
createContextMenuItems(menuContext) {
|
|
12
12
|
if (!this.isModuleAvailable()) {
|
|
13
13
|
return;
|
|
14
14
|
}
|
|
@@ -29,19 +29,6 @@ class Fdc3Module extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
29
29
|
contextMenuItems.push(this.buildBroadcastMenuItem(broadcastConfig, currentRowNode));
|
|
30
30
|
});
|
|
31
31
|
contextMenuItems.sort((a, b) => a.label.localeCompare(b.label));
|
|
32
|
-
if (contextMenuItems.length > 1) {
|
|
33
|
-
const groupMenuItem = {
|
|
34
|
-
name: 'fdc3-parent',
|
|
35
|
-
module: this.moduleInfo.ModuleName,
|
|
36
|
-
label: 'FDC3',
|
|
37
|
-
icon: {
|
|
38
|
-
name: 'fdc3',
|
|
39
|
-
},
|
|
40
|
-
isVisible: true,
|
|
41
|
-
subItems: contextMenuItems,
|
|
42
|
-
};
|
|
43
|
-
return [groupMenuItem];
|
|
44
|
-
}
|
|
45
32
|
return contextMenuItems;
|
|
46
33
|
}
|
|
47
34
|
}
|
|
@@ -15,8 +15,8 @@ export declare class FlashingCellModule extends AdaptableModuleBase implements I
|
|
|
15
15
|
}): AdaptableObject[];
|
|
16
16
|
getExplicitlyReferencedColumnIds(alertDefinition: FlashingCellDefinition): string[];
|
|
17
17
|
getReferencedNamedQueryNames(alertDefinition: FlashingCellDefinition): string[];
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
createColumnMenuItems(column: AdaptableColumn): AdaptableMenuItem[] | undefined;
|
|
19
|
+
createContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
20
20
|
protected handleCellDataChanged(cellDataChangedInfo: CellDataChangedInfo): void;
|
|
21
21
|
private showFlashingCellsForDefinitions;
|
|
22
22
|
private isFlashingTargetOnlyAggChange;
|
|
@@ -64,7 +64,7 @@ class FlashingCellModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
64
64
|
}
|
|
65
65
|
return this.api.namedQueryApi.internalApi.getReferencedNamedQueryNames(queryExpression);
|
|
66
66
|
}
|
|
67
|
-
|
|
67
|
+
createColumnMenuItems(column) {
|
|
68
68
|
if (column && this.isModuleEditable()) {
|
|
69
69
|
if (!this.api.columnApi.isCalculatedColumn(column.columnId)) {
|
|
70
70
|
const flashingCellDefinitions = this.api.flashingCellApi.getFlashingCellDefinitions();
|
|
@@ -89,7 +89,7 @@ class FlashingCellModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
89
89
|
}
|
|
90
90
|
}
|
|
91
91
|
}
|
|
92
|
-
|
|
92
|
+
createContextMenuItems(menuContext) {
|
|
93
93
|
const items = [];
|
|
94
94
|
if (!menuContext.isRowGroupColumn && this.isModuleAvailable()) {
|
|
95
95
|
if (menuContext.adaptableColumn && menuContext.rowNode) {
|
|
@@ -13,7 +13,7 @@ export declare class FormatColumnModule extends AdaptableModuleBase implements I
|
|
|
13
13
|
}): AdaptableObject[];
|
|
14
14
|
getExplicitlyReferencedColumnIds(formatColumn: FormatColumn): string[];
|
|
15
15
|
getReferencedNamedQueryNames(formatColumn: FormatColumn): string[];
|
|
16
|
-
|
|
16
|
+
createColumnMenuItems(column: AdaptableColumn): AdaptableMenuItem[] | undefined;
|
|
17
17
|
getTeamSharingAction(): TeamSharingImportInfo<FormatColumn>;
|
|
18
18
|
toView(formatColumn: FormatColumn): AdaptableObjectView;
|
|
19
19
|
toViewAll(): AdaptableObjectView[];
|