@adaptabletools/adaptable 16.0.0 → 16.0.1-canary.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundle.cjs.js +162 -164
- package/package.json +1 -1
- package/publishTimestamp.d.ts +1 -1
- package/publishTimestamp.js +1 -1
- package/src/AdaptableInterfaces/IAdaptable.d.ts +2 -1
- package/src/AdaptableOptions/AdaptableOptions.d.ts +6 -1
- package/src/AdaptableOptions/CalendarOptions.d.ts +3 -3
- package/src/AdaptableOptions/CommentsOptions.d.ts +23 -0
- package/src/AdaptableOptions/Fdc3Options.d.ts +65 -48
- package/src/AdaptableOptions/FilterOptions.d.ts +7 -2
- package/src/AdaptableOptions/FinancePluginOptions.d.ts +2 -306
- package/src/AdaptableOptions/OpenFinPluginOptions.d.ts +0 -6
- package/src/AdaptableOptions/UserInterfaceOptions.d.ts +0 -17
- package/src/Api/CommentsApi.d.ts +6 -6
- package/src/Api/EventApi.d.ts +2 -14
- package/src/Api/GridApi.d.ts +13 -13
- package/src/Api/Implementation/ApiBase.d.ts +2 -0
- package/src/Api/Implementation/ApiBase.js +3 -0
- package/src/Api/Implementation/CalendarApiImpl.js +1 -2
- package/src/Api/Implementation/CommentsApiImpl.d.ts +3 -3
- package/src/Api/Implementation/CommentsApiImpl.js +3 -3
- package/src/Api/Implementation/GridApiImpl.js +2 -2
- package/src/Api/Implementation/OptionsApiImpl.d.ts +2 -1
- package/src/Api/Implementation/OptionsApiImpl.js +3 -0
- package/src/Api/Implementation/PluginsApiImpl.d.ts +0 -2
- package/src/Api/Implementation/PluginsApiImpl.js +0 -6
- package/src/Api/Internal/AdaptableInternalApi.js +1 -1
- package/src/Api/Internal/Fdc3InternalApi.d.ts +2 -0
- package/src/Api/Internal/Fdc3InternalApi.js +13 -2
- package/src/Api/OptionsApi.d.ts +5 -1
- package/src/Api/PluginsApi.d.ts +0 -5
- package/src/PredefinedConfig/CommentsState.d.ts +30 -3
- package/src/PredefinedConfig/Common/Entitlement.d.ts +1 -1
- package/src/PredefinedConfig/Common/Fdc3Context.d.ts +6 -0
- package/src/PredefinedConfig/SystemState.d.ts +2 -2
- package/src/Redux/ActionsReducers/SystemRedux.d.ts +4 -4
- package/src/Strategy/CommentsModule.d.ts +2 -2
- package/src/Strategy/CommentsModule.js +11 -11
- package/src/Strategy/Fdc3Module.d.ts +0 -1
- package/src/Strategy/Fdc3Module.js +0 -3
- package/src/Utilities/Constants/GeneralConstants.d.ts +0 -1
- package/src/Utilities/Constants/GeneralConstants.js +2 -3
- package/src/Utilities/Defaults/DefaultAdaptableOptions.js +1 -1
- package/src/Utilities/Services/Fdc3Service.js +9 -4
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/ConfigurationWizard.js +10 -7
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/FinanceForm.d.ts +1 -7
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/FinanceForm.js +621 -268
- package/src/View/Comments/CommentPopup.js +5 -5
- package/src/agGrid/Adaptable.d.ts +2 -1
- package/src/agGrid/Adaptable.js +5 -1
- package/src/agGrid/attachAddaptableColumnTypes.js +1 -0
- package/src/metamodel/adaptable.metamodel.d.ts +45 -404
- package/src/metamodel/adaptable.metamodel.js +1 -1
- package/src/types.d.ts +4 -6
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/src/Api/FinanceApi.d.ts +0 -125
- package/src/PredefinedConfig/Common/FDC3Context_DEPR.d.ts +0 -246
- package/src/PredefinedConfig/Common/FDC3Context_DEPR.js +0 -2
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/index.d.ts +0 -1
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/index.js +0 -5
- /package/src/{Api/FinanceApi.js → AdaptableOptions/CommentsOptions.js} +0 -0
|
@@ -110,10 +110,6 @@ export interface UserInterfaceOptions<TData = any> {
|
|
|
110
110
|
* @defaultValue null
|
|
111
111
|
*/
|
|
112
112
|
alternativeModuleNames?: AlternativeModuleName[];
|
|
113
|
-
/**
|
|
114
|
-
* Whether a cell can be commented on
|
|
115
|
-
*/
|
|
116
|
-
isCellCommentable?: (context: CommmentableCellContext) => boolean;
|
|
117
113
|
}
|
|
118
114
|
/**
|
|
119
115
|
* Base class for all Permitted Values related objects
|
|
@@ -210,19 +206,6 @@ export interface BulkUpdatePermittedValuesContext<TData = any> extends Permitted
|
|
|
210
206
|
*/
|
|
211
207
|
gridCells: GridCell<TData>[];
|
|
212
208
|
}
|
|
213
|
-
/**
|
|
214
|
-
* Context used when determining if a Comment can be added to a Cell
|
|
215
|
-
*/
|
|
216
|
-
export interface CommmentableCellContext extends BaseContext {
|
|
217
|
-
/**
|
|
218
|
-
* Value in Primary Key Column
|
|
219
|
-
*/
|
|
220
|
-
primaryKeyValue: string;
|
|
221
|
-
/**
|
|
222
|
-
* Column where Comment will be displayed
|
|
223
|
-
*/
|
|
224
|
-
columnId: string;
|
|
225
|
-
}
|
|
226
209
|
/**
|
|
227
210
|
* Sets of Tabs avilable in Grid Info Settings Panel
|
|
228
211
|
*/
|
package/src/Api/CommentsApi.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AdaptableComment, AdaptableComments,
|
|
1
|
+
import { AdaptableComment, AdaptableComments, CommentGridCell, CommentsState } from '../PredefinedConfig/CommentsState';
|
|
2
2
|
/**
|
|
3
3
|
* Provides run-time access to Comments Module and related State
|
|
4
4
|
*/
|
|
@@ -21,9 +21,9 @@ export interface CommentsApi {
|
|
|
21
21
|
getAllComments(): AdaptableComments;
|
|
22
22
|
/**
|
|
23
23
|
* Gets all comments for a cell
|
|
24
|
-
* @param
|
|
24
|
+
* @param commentGridCell comment position
|
|
25
25
|
*/
|
|
26
|
-
getCellComments(
|
|
26
|
+
getCellComments(commentGridCell: CommentGridCell): AdaptableComment[];
|
|
27
27
|
/**
|
|
28
28
|
* Returns a comment by uuid
|
|
29
29
|
* @param uuid comment uuid
|
|
@@ -31,10 +31,10 @@ export interface CommentsApi {
|
|
|
31
31
|
getCommentByUuid(uuid: string): AdaptableComment | undefined;
|
|
32
32
|
/**
|
|
33
33
|
* Gets all comments for a cell
|
|
34
|
-
* @param
|
|
34
|
+
* @param commentGridCell comment position
|
|
35
35
|
* @param editMode whether to show the comment in edit mode
|
|
36
36
|
*/
|
|
37
|
-
showComment(
|
|
37
|
+
showComment(commentGridCell: CommentGridCell, editMode?: boolean): void;
|
|
38
38
|
/**
|
|
39
39
|
* Hides the comment popup
|
|
40
40
|
*/
|
|
@@ -42,7 +42,7 @@ export interface CommentsApi {
|
|
|
42
42
|
/**
|
|
43
43
|
* Gets the comment position of the currently open comment popup
|
|
44
44
|
*/
|
|
45
|
-
|
|
45
|
+
getOpenCommentGridCell(): CommentGridCell | null;
|
|
46
46
|
/**
|
|
47
47
|
* Gets the comment edit mode
|
|
48
48
|
*/
|
package/src/Api/EventApi.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { SelectionChangedInfo, LiveDataChangedInfo, DashboardChangedInfo, ThemeChangedInfo, AlertFiredInfo, LayoutChangedInfo, AdaptableReadyInfo, CustomToolbarConfiguredInfo, CellChangedInfo, SystemStatusMessageDisplayedInfo, CheckboxColumnClickedInfo, AdaptableStateChangedInfo, FlashingCellDisplayedInfo, GridDataChangedInfo, TeamSharingEntityChangedInfo, ActionRowSubmittedInfo, DataSetSelectedInfo, AdaptableStateReloadedInfo, GridSortedInfo, QueryRunInfo, ScheduleTriggeredInfo, ChartChangedInfo, ThemeEditedInfo, FilterAppliedInfo } from '../types';
|
|
2
2
|
/**
|
|
3
3
|
* Responsible for publishing the many Events that AdapTable fires
|
|
4
4
|
*/
|
|
@@ -308,21 +308,9 @@ export interface EventApi {
|
|
|
308
308
|
* Unsubscribe from AdaptableReady
|
|
309
309
|
*/
|
|
310
310
|
off(eventName: 'AdaptableReady', callback: (adaptableReadyInfo: AdaptableReadyInfo) => void): void;
|
|
311
|
-
/**
|
|
312
|
-
* Fired when an FDC3Message is sent
|
|
313
|
-
* @param eventName - FDC3MessageSent
|
|
314
|
-
* @param callback - A callback for listening to `FDC3MessageSent`
|
|
315
|
-
* @returns the unsubscribe function
|
|
316
|
-
*
|
|
317
|
-
*/
|
|
318
|
-
on(eventName: 'FDC3MessageSent', callback: (eventInfo: AdaptableFDC3EventInfo) => void): VoidFunction;
|
|
319
|
-
/**
|
|
320
|
-
* Unsubscribe from FDC3MessageSent
|
|
321
|
-
*/
|
|
322
|
-
off(eventName: 'FDC3MessageSent', callback: (eventInfo: AdaptableFDC3EventInfo) => void): void;
|
|
323
311
|
emitSync(eventName: 'DashboardChanged', data?: any): any[];
|
|
324
312
|
emitSync(eventName: 'FlashingCellDisplayed', data?: any): any[];
|
|
325
313
|
emitSync(eventName: 'AdaptableDestroy'): any[];
|
|
326
|
-
emit(eventName: 'ActionRowSubmitted' | 'AdaptableReady' | 'AlertFired' | 'AdaptableStateChanged' | 'AdaptableStateReloaded' | 'CellChanged' | 'ChartChanged' | 'CheckboxColumnClicked' | 'CustomToolbarConfigured' | 'DashboardChanged' | 'DataSetSelected' | '
|
|
314
|
+
emit(eventName: 'ActionRowSubmitted' | 'AdaptableReady' | 'AlertFired' | 'AdaptableStateChanged' | 'AdaptableStateReloaded' | 'CellChanged' | 'ChartChanged' | 'CheckboxColumnClicked' | 'CustomToolbarConfigured' | 'DashboardChanged' | 'DataSetSelected' | 'FilterApplied' | 'GridDataChanged' | 'GridSorted' | 'LayoutChanged' | 'LiveDataChanged' | 'QueryRun' | 'ScheduleTriggered' | 'SearchChanged' | 'SelectionChanged' | 'SystemStatusMessageDisplayed' | 'TeamSharingEntityChanged' | 'ThemeChanged' | 'ThemeEdited', data?: any): Promise<any>;
|
|
327
315
|
destroy(): void;
|
|
328
316
|
}
|
package/src/Api/GridApi.d.ts
CHANGED
|
@@ -15,7 +15,7 @@ import { RowsHighlightInfo } from '../PredefinedConfig/Common/RowsHighlightInfo'
|
|
|
15
15
|
*/
|
|
16
16
|
export interface GridApi {
|
|
17
17
|
/**
|
|
18
|
-
* Returns Grid section from
|
|
18
|
+
* Returns Grid section from AdapTable State
|
|
19
19
|
*/
|
|
20
20
|
getGridState(): GridState;
|
|
21
21
|
/**
|
|
@@ -27,41 +27,41 @@ export interface GridApi {
|
|
|
27
27
|
*/
|
|
28
28
|
getFilteredData(): any[];
|
|
29
29
|
/**
|
|
30
|
-
* Repopulates grid with given data
|
|
31
|
-
* @param data any data
|
|
30
|
+
* Repopulates EXISTING grid with given data; fires GridDataChanged' Event
|
|
31
|
+
* @param data any data suitable as AG Grid data source
|
|
32
32
|
*/
|
|
33
33
|
setGridData(data: any[]): void;
|
|
34
34
|
/**
|
|
35
|
-
* Sets grid with given data;
|
|
36
|
-
* @param
|
|
35
|
+
* Sets grid with given data for FIRST use; doesn't fire 'GridDataChanged' Event
|
|
36
|
+
* @param dataany data suitable as AG Grid data source
|
|
37
37
|
*/
|
|
38
38
|
setInitialGridData(data: any): void;
|
|
39
39
|
/**
|
|
40
|
-
* Updates
|
|
41
|
-
* @param dataRows rows which have been updated - send whole row and
|
|
40
|
+
* Updates AdapTable (and AG Grid) with rows that have changed
|
|
41
|
+
* @param dataRows rows which have been updated - send whole row and AdapTable take cares of the rest
|
|
42
42
|
* @param config batch option and callback function to run post update
|
|
43
43
|
*/
|
|
44
44
|
updateGridData(dataRows: any[], config?: DataUpdateConfig): Promise<IRowNode[]>;
|
|
45
45
|
/**
|
|
46
|
-
* Adds or Updates
|
|
46
|
+
* Adds or Updates AdapTable (and AG Grid) with new and changed rows
|
|
47
47
|
* @param dataRows rows to add or update
|
|
48
48
|
* @param config batch option and callback function to run post change
|
|
49
49
|
*/
|
|
50
50
|
addOrUpdateGridData(dataRows: any[], config?: DataUpdateConfig): Promise<IRowNode[]>;
|
|
51
51
|
/**
|
|
52
|
-
* Adds rows to
|
|
52
|
+
* Adds rows to AdapTable (and AG Grid)
|
|
53
53
|
* @param dataRows rows to add; ensure all 'mandatory' fields are included and Primary Key is unique
|
|
54
54
|
* @param config batch option and callback function to run post addition
|
|
55
55
|
*/
|
|
56
56
|
addGridData(dataRows: any[], config?: DataUpdateConfig): Promise<IRowNode[]>;
|
|
57
57
|
/**
|
|
58
|
-
* Deletes rows from
|
|
58
|
+
* Deletes rows from AdapTable (and AG Grid)
|
|
59
59
|
* @param dataRows rows which should be deleted
|
|
60
60
|
* @param config batch option and callback function to run post deletion
|
|
61
61
|
*/
|
|
62
62
|
deleteGridData(dataRows: any[], config?: DataUpdateConfig): Promise<IRowNode[]>;
|
|
63
63
|
/**
|
|
64
|
-
* Updates cell in
|
|
64
|
+
* Updates cell in AdapTable (first performs Cell & Server Validation)
|
|
65
65
|
* @param cellUpdateRequest (contains columnId, newValue and primaryKeyValue
|
|
66
66
|
*
|
|
67
67
|
*/
|
|
@@ -88,7 +88,7 @@ export interface GridApi {
|
|
|
88
88
|
*/
|
|
89
89
|
getAgGridInstance(): GridOptions;
|
|
90
90
|
/**
|
|
91
|
-
* Returns Column Sort information in
|
|
91
|
+
* Returns Column Sort information in AdapTable
|
|
92
92
|
*/
|
|
93
93
|
getColumnSorts(): ColumnSort[];
|
|
94
94
|
/**
|
|
@@ -497,7 +497,7 @@ export interface GridApi {
|
|
|
497
497
|
*/
|
|
498
498
|
deselectAll(): void;
|
|
499
499
|
/**
|
|
500
|
-
* Returns the Grid Container in which the
|
|
500
|
+
* Returns the Grid Container in which the AdapTable Instance is present
|
|
501
501
|
*/
|
|
502
502
|
getGridContainerElement(): HTMLElement | null;
|
|
503
503
|
/**
|
|
@@ -21,6 +21,7 @@ import { ExpressionApi } from '../ExpressionApi';
|
|
|
21
21
|
import { CalendarOptions } from '../../AdaptableOptions/CalendarOptions';
|
|
22
22
|
import { Fdc3Api } from '../Fdc3Api';
|
|
23
23
|
import { Fdc3Options } from '../../AdaptableOptions/Fdc3Options';
|
|
24
|
+
import { CommentOptions } from '../../AdaptableOptions/CommentsOptions';
|
|
24
25
|
export declare abstract class ApiBase {
|
|
25
26
|
protected adaptable: IAdaptable;
|
|
26
27
|
/**
|
|
@@ -64,6 +65,7 @@ export declare abstract class ApiBase {
|
|
|
64
65
|
protected getActionColumnOptions(): ActionColumnOptions;
|
|
65
66
|
protected getActionRowOptions(): ActionRowOptions;
|
|
66
67
|
protected getColumnOptions(): ColumnOptions;
|
|
68
|
+
protected getCommentOptions(): CommentOptions;
|
|
67
69
|
protected getCustomSortOptions(): CustomSortOptions;
|
|
68
70
|
protected getDataSetOptions(): DataSetOptions;
|
|
69
71
|
protected getCalendarOptions(): CalendarOptions;
|
|
@@ -102,6 +102,9 @@ class ApiBase {
|
|
|
102
102
|
getColumnOptions() {
|
|
103
103
|
return this.getOptions().columnOptions;
|
|
104
104
|
}
|
|
105
|
+
getCommentOptions() {
|
|
106
|
+
return this.getOptions().commentOptions;
|
|
107
|
+
}
|
|
105
108
|
getCustomSortOptions() {
|
|
106
109
|
return this.getOptions().customSortOptions;
|
|
107
110
|
}
|
|
@@ -27,8 +27,7 @@ class CalendarApiImpl extends ApiBase_1.ApiBase {
|
|
|
27
27
|
return dateToCheck.getDay() != 0 && dateToCheck.getDay() != 6;
|
|
28
28
|
}
|
|
29
29
|
for (let holiday of holidays) {
|
|
30
|
-
|
|
31
|
-
if (holidayDate.setHours(0, 0, 0, 0) == dateToCheck.setHours(0, 0, 0, 0)) {
|
|
30
|
+
if (holiday.setHours(0, 0, 0, 0) == dateToCheck.setHours(0, 0, 0, 0)) {
|
|
32
31
|
return false;
|
|
33
32
|
}
|
|
34
33
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ApiBase } from './ApiBase';
|
|
2
2
|
import { CommentsApi } from '../CommentsApi';
|
|
3
|
-
import { AdaptableComment, AdaptableComments,
|
|
3
|
+
import { AdaptableComment, AdaptableComments, CommentGridCell, CommentsState } from '../../PredefinedConfig/CommentsState';
|
|
4
4
|
export declare class CommentsApiImpl extends ApiBase implements CommentsApi {
|
|
5
5
|
addComment(comment: string, primaryKeyValue: any, columnId: string): void;
|
|
6
6
|
editComment(adaptableComment: AdaptableComment): void;
|
|
@@ -13,8 +13,8 @@ export declare class CommentsApiImpl extends ApiBase implements CommentsApi {
|
|
|
13
13
|
ColumnId: string;
|
|
14
14
|
}): AdaptableComments;
|
|
15
15
|
getCommentByUuid(uuid: string): AdaptableComment | undefined;
|
|
16
|
-
showComment(
|
|
16
|
+
showComment(commentGridCell: CommentGridCell, editMode?: boolean): void;
|
|
17
17
|
hideComment(): void;
|
|
18
|
-
|
|
18
|
+
getOpenCommentGridCell(): CommentGridCell | undefined;
|
|
19
19
|
getCommentPopupEditMode(): boolean;
|
|
20
20
|
}
|
|
@@ -43,13 +43,13 @@ class CommentsApiImpl extends ApiBase_1.ApiBase {
|
|
|
43
43
|
getCommentByUuid(uuid) {
|
|
44
44
|
return this.getAllComments().find((comment) => comment.Uuid === uuid);
|
|
45
45
|
}
|
|
46
|
-
showComment(
|
|
47
|
-
this.dispatchAction(SystemRedux.SystemCommentsShow(
|
|
46
|
+
showComment(commentGridCell, editMode) {
|
|
47
|
+
this.dispatchAction(SystemRedux.SystemCommentsShow(commentGridCell, editMode));
|
|
48
48
|
}
|
|
49
49
|
hideComment() {
|
|
50
50
|
this.dispatchAction(SystemRedux.SystemCommentsHide());
|
|
51
51
|
}
|
|
52
|
-
|
|
52
|
+
getOpenCommentGridCell() {
|
|
53
53
|
return SystemRedux.SystemCommentsSelector(this.getAdaptableState().System);
|
|
54
54
|
}
|
|
55
55
|
getCommentPopupEditMode() {
|
|
@@ -17,12 +17,12 @@ class GridApiImpl extends ApiBase_1.ApiBase {
|
|
|
17
17
|
return this.getAdaptableState().Grid;
|
|
18
18
|
}
|
|
19
19
|
setGridData(dataSource) {
|
|
20
|
-
this.adaptable.
|
|
20
|
+
this.adaptable.setGridData(dataSource);
|
|
21
21
|
const allRowNodes = this.getAllRowNodes();
|
|
22
22
|
this.internalApi.fireGridDataChangedEvent(dataSource, allRowNodes, 'Add');
|
|
23
23
|
}
|
|
24
24
|
setInitialGridData(data) {
|
|
25
|
-
this.adaptable.
|
|
25
|
+
this.adaptable.setInitialGridData(data);
|
|
26
26
|
}
|
|
27
27
|
getGridData() {
|
|
28
28
|
return this.adaptable.getGridData();
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ApiBase } from './ApiBase';
|
|
2
|
-
import { ActionColumnOptions, ActionRowOptions, AdaptableOptions, AdaptableQLOptions, AlertOptions, CalendarOptions, CellSummaryOptions, ChartingOptions, ColumnOptions, ContainerOptions, DashboardOptions, DataChangeHistoryOptions, DataSetOptions, EditOptions, EntitlementOptions, ExportOptions, FilterOptions, FlashingCellOptions, FormatColumnOptions, LayoutOptions, MenuOptions, NotificationsOptions, OptionsApi, QuickSearchOptions, SettingsPanelOptions, StateOptions, TeamSharingOptions, ToolPanelOptions, UserInterfaceOptions } from '../../types';
|
|
2
|
+
import { ActionColumnOptions, ActionRowOptions, AdaptableOptions, AdaptableQLOptions, AlertOptions, CalendarOptions, CellSummaryOptions, ChartingOptions, ColumnOptions, CommentOptions, ContainerOptions, DashboardOptions, DataChangeHistoryOptions, DataSetOptions, EditOptions, EntitlementOptions, ExportOptions, FilterOptions, FlashingCellOptions, FormatColumnOptions, LayoutOptions, MenuOptions, NotificationsOptions, OptionsApi, QuickSearchOptions, SettingsPanelOptions, StateOptions, TeamSharingOptions, ToolPanelOptions, UserInterfaceOptions } from '../../types';
|
|
3
3
|
import { GroupingOptions } from '../../AdaptableOptions/GroupingOptions';
|
|
4
4
|
import { CustomSortOptions } from '../../AdaptableOptions/CustomSortOptions';
|
|
5
5
|
import { Fdc3Options } from '../../AdaptableOptions/Fdc3Options';
|
|
@@ -16,6 +16,7 @@ export declare class OptionsApiImpl extends ApiBase implements OptionsApi {
|
|
|
16
16
|
getCellSummaryOptions(): CellSummaryOptions;
|
|
17
17
|
getCalendarOptions(): CalendarOptions;
|
|
18
18
|
getColumnOptions(): ColumnOptions;
|
|
19
|
+
getCommentOptions(): CommentOptions;
|
|
19
20
|
getCustomSortOptions(): CustomSortOptions;
|
|
20
21
|
getContainerOptions(): ContainerOptions;
|
|
21
22
|
getDataSetOptions(): DataSetOptions;
|
|
@@ -39,6 +39,9 @@ class OptionsApiImpl extends ApiBase_1.ApiBase {
|
|
|
39
39
|
getColumnOptions() {
|
|
40
40
|
return this.getOptions().columnOptions;
|
|
41
41
|
}
|
|
42
|
+
getCommentOptions() {
|
|
43
|
+
return this.getOptions().commentOptions;
|
|
44
|
+
}
|
|
42
45
|
getCustomSortOptions() {
|
|
43
46
|
return this.getOptions().customSortOptions;
|
|
44
47
|
}
|
|
@@ -4,7 +4,6 @@ import { ApiBase } from './ApiBase';
|
|
|
4
4
|
import { IPushPullApi } from '../IPushPullApi';
|
|
5
5
|
import { Glue42Api } from '../Glue42Api';
|
|
6
6
|
import { OpenFinApi } from '../OpenFinApi';
|
|
7
|
-
import { FinanceApi } from '../FinanceApi';
|
|
8
7
|
import { FinsembleApi } from '../FinsembleApi';
|
|
9
8
|
import { Glue42WebApi } from '../Glue42WebApi';
|
|
10
9
|
export declare class PluginsApiImpl extends ApiBase implements PluginsApi {
|
|
@@ -17,6 +16,5 @@ export declare class PluginsApiImpl extends ApiBase implements PluginsApi {
|
|
|
17
16
|
getGlue42PluginApi(): Glue42Api;
|
|
18
17
|
getGlue42WebPluginApi(): Glue42WebApi;
|
|
19
18
|
getOpenFinPluginApi(): OpenFinApi;
|
|
20
|
-
getFinancePluginApi(): FinanceApi;
|
|
21
19
|
getFinsemblePluginApi(): FinsembleApi;
|
|
22
20
|
}
|
|
@@ -23,9 +23,6 @@ class PluginsApiImpl extends ApiBase_1.ApiBase {
|
|
|
23
23
|
if (pluginId === 'ipushpull') {
|
|
24
24
|
return api;
|
|
25
25
|
}
|
|
26
|
-
if (pluginId === 'finance') {
|
|
27
|
-
return api;
|
|
28
|
-
}
|
|
29
26
|
if (pluginId === 'glue42') {
|
|
30
27
|
return api;
|
|
31
28
|
}
|
|
@@ -56,9 +53,6 @@ class PluginsApiImpl extends ApiBase_1.ApiBase {
|
|
|
56
53
|
getOpenFinPluginApi() {
|
|
57
54
|
return this.getPluginApi('openfin');
|
|
58
55
|
}
|
|
59
|
-
getFinancePluginApi() {
|
|
60
|
-
return this.getPluginApi('finance');
|
|
61
|
-
}
|
|
62
56
|
getFinsemblePluginApi() {
|
|
63
57
|
return this.getPluginApi('finsemble');
|
|
64
58
|
}
|
|
@@ -467,7 +467,7 @@ class AdaptableInternalApi extends ApiBase_1.ApiBase {
|
|
|
467
467
|
if (!actionColumn && this.getFdc3Api().internalApi.isFdc3MainActionColumn(colDef.colId)) {
|
|
468
468
|
const actionButtons = this.getFdc3Api().internalApi.getButtonsForFdc3MainActionColumn();
|
|
469
469
|
actionColumn = {
|
|
470
|
-
columnId:
|
|
470
|
+
columnId: this.getFdc3Options().actionColumnDefaultConfiguration.columnId,
|
|
471
471
|
actionColumnButton: actionButtons,
|
|
472
472
|
};
|
|
473
473
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ApiBase } from '../Implementation/ApiBase';
|
|
2
2
|
import { Fdc3Context, Fdc3ContextType, Fdc3CustomContextType } from '../../PredefinedConfig/Common/Fdc3Context';
|
|
3
3
|
import { ColDef, IRowNode } from '@ag-grid-community/core';
|
|
4
|
+
import { AppIdentifier, Context, IntentResolution } from '@finos/fdc3';
|
|
4
5
|
import { AdaptableButton } from '../../PredefinedConfig/Common/AdaptableButton';
|
|
5
6
|
import { ActionColumnContext } from '../../AdaptableOptions/ActionColumnOptions';
|
|
6
7
|
export declare class Fdc3InternalApi extends ApiBase {
|
|
@@ -14,6 +15,7 @@ export declare class Fdc3InternalApi extends ApiBase {
|
|
|
14
15
|
getButtonsForFdc3StandaloneActionColumn(columnId: string): AdaptableButton<ActionColumnContext<any>>[];
|
|
15
16
|
isFdc3MainActionColumn(columnId: string): boolean;
|
|
16
17
|
isFdc3StandaloneActionColumn(columnId: string, columnType: string | string[]): boolean;
|
|
18
|
+
handleIntentResolution(intentResolution: IntentResolution, context: Context, raisedIntent: string, app?: AppIdentifier): void;
|
|
17
19
|
private isAtLeastOneActionButtonConfigured;
|
|
18
20
|
private getIntentConfigsWithActionButtons;
|
|
19
21
|
private getCustomIntentConfigsWithActionButtons;
|
|
@@ -43,7 +43,7 @@ class Fdc3InternalApi extends ApiBase_1.ApiBase {
|
|
|
43
43
|
if (this.isAtLeastOneActionButtonConfigured()) {
|
|
44
44
|
const actionColumnConfig = this.getFdc3Options().actionColumnDefaultConfiguration;
|
|
45
45
|
actionColDefs.push({
|
|
46
|
-
colId:
|
|
46
|
+
colId: actionColumnConfig.columnId,
|
|
47
47
|
headerName: actionColumnConfig.headerName,
|
|
48
48
|
hide: false,
|
|
49
49
|
lockVisible: true,
|
|
@@ -241,12 +241,23 @@ class Fdc3InternalApi extends ApiBase_1.ApiBase {
|
|
|
241
241
|
return buttons;
|
|
242
242
|
}
|
|
243
243
|
isFdc3MainActionColumn(columnId) {
|
|
244
|
-
return columnId ===
|
|
244
|
+
return columnId === this.getFdc3Options().actionColumnDefaultConfiguration.columnId;
|
|
245
245
|
}
|
|
246
246
|
isFdc3StandaloneActionColumn(columnId, columnType) {
|
|
247
247
|
const types = typeof columnType === 'string' ? [columnType] : columnType;
|
|
248
248
|
return types.includes(GeneralConstants_1.AB_FDC3_COLUMN) && !this.isFdc3MainActionColumn(columnId);
|
|
249
249
|
}
|
|
250
|
+
handleIntentResolution(intentResolution, context, raisedIntent, app) {
|
|
251
|
+
var _a, _b, _c;
|
|
252
|
+
const raiseIntents = (_a = this.getFdc3Options().intents) === null || _a === void 0 ? void 0 : _a.raises;
|
|
253
|
+
const raiseCustomIntents = (_b = this.getFdc3Options().customIntents) === null || _b === void 0 ? void 0 : _b.raises;
|
|
254
|
+
const raiseAllIntents = Object.assign(Object.assign({}, raiseIntents), raiseCustomIntents);
|
|
255
|
+
const raiseIntentConfig = raiseAllIntents === null || raiseAllIntents === void 0 ? void 0 : raiseAllIntents[raisedIntent];
|
|
256
|
+
if (raiseIntentConfig === null || raiseIntentConfig === void 0 ? void 0 : raiseIntentConfig.length) {
|
|
257
|
+
const relevantContextConfig = raiseIntentConfig.find((config) => config.contextType === context.type);
|
|
258
|
+
(_c = relevantContextConfig === null || relevantContextConfig === void 0 ? void 0 : relevantContextConfig.handleIntentResolution) === null || _c === void 0 ? void 0 : _c.call(relevantContextConfig, Object.assign(Object.assign({}, this.getAdaptableApi().internalApi.buildBaseContext()), { intentResolution }));
|
|
259
|
+
}
|
|
260
|
+
}
|
|
250
261
|
isAtLeastOneActionButtonConfigured() {
|
|
251
262
|
return (!!Object.keys(this.getIntentConfigsWithActionButtons()).length ||
|
|
252
263
|
!!Object.keys(this.getContextConfigsWithActionButtons()).length ||
|
package/src/Api/OptionsApi.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { CustomSortOptions } from '../AdaptableOptions/CustomSortOptions';
|
|
2
2
|
import { DataSetOptions } from '../AdaptableOptions/DataSetOptions';
|
|
3
3
|
import { GroupingOptions } from '../AdaptableOptions/GroupingOptions';
|
|
4
|
-
import { ActionColumnOptions, ActionRowOptions, AdaptableOptions, AdaptableQLOptions, AlertOptions, CalendarOptions, CellSummaryOptions, ChartingOptions, ColumnOptions, ContainerOptions, DashboardOptions, DataChangeHistoryOptions, EditOptions, EntitlementOptions, ExportOptions, FilterOptions, FlashingCellOptions, FormatColumnOptions, LayoutOptions, MenuOptions, NotificationsOptions, QuickSearchOptions, SettingsPanelOptions, StateOptions, TeamSharingOptions, ToolPanelOptions, UserInterfaceOptions } from '../types';
|
|
4
|
+
import { ActionColumnOptions, ActionRowOptions, AdaptableOptions, AdaptableQLOptions, AlertOptions, CalendarOptions, CellSummaryOptions, ChartingOptions, ColumnOptions, CommentOptions, ContainerOptions, DashboardOptions, DataChangeHistoryOptions, EditOptions, EntitlementOptions, ExportOptions, FilterOptions, FlashingCellOptions, FormatColumnOptions, LayoutOptions, MenuOptions, NotificationsOptions, QuickSearchOptions, SettingsPanelOptions, StateOptions, TeamSharingOptions, ToolPanelOptions, UserInterfaceOptions } from '../types';
|
|
5
5
|
import { Fdc3Options } from '../AdaptableOptions/Fdc3Options';
|
|
6
6
|
/**
|
|
7
7
|
* Range of functions to access Adaptable Options
|
|
@@ -71,6 +71,10 @@ export interface OptionsApi {
|
|
|
71
71
|
* Returns `AdaptableOptions.columnOptions`
|
|
72
72
|
*/
|
|
73
73
|
getColumnOptions(): Readonly<ColumnOptions>;
|
|
74
|
+
/**
|
|
75
|
+
* Returns `AdaptableOptions.commentOptions`
|
|
76
|
+
*/
|
|
77
|
+
getCommentOptions(): Readonly<CommentOptions>;
|
|
74
78
|
/**
|
|
75
79
|
* Returns `AdaptableOptions.customSortOptions`
|
|
76
80
|
*/
|
package/src/Api/PluginsApi.d.ts
CHANGED
|
@@ -2,7 +2,6 @@ import { PluginsState } from '../Redux/ActionsReducers/PluginsRedux';
|
|
|
2
2
|
import { IPushPullApi } from './IPushPullApi';
|
|
3
3
|
import { Glue42Api } from './Glue42Api';
|
|
4
4
|
import { OpenFinApi } from './OpenFinApi';
|
|
5
|
-
import { FinanceApi } from './FinanceApi';
|
|
6
5
|
import { FinsembleApi } from './FinsembleApi';
|
|
7
6
|
import { Glue42WebApi } from './Glue42WebApi';
|
|
8
7
|
/**
|
|
@@ -46,10 +45,6 @@ export interface PluginsApi {
|
|
|
46
45
|
* Returns OpenFin API class in Adaptable API
|
|
47
46
|
*/
|
|
48
47
|
getOpenFinPluginApi(): OpenFinApi;
|
|
49
|
-
/**
|
|
50
|
-
* Returns Finance API class in Adaptable API
|
|
51
|
-
*/
|
|
52
|
-
getFinancePluginApi(): FinanceApi;
|
|
53
48
|
/**
|
|
54
49
|
* Returns Finsemble API class in Adaptable API
|
|
55
50
|
*/
|
|
@@ -4,26 +4,53 @@ import { ConfigState } from './ConfigState';
|
|
|
4
4
|
* Comment that can be applied to a Cell in AdapTable
|
|
5
5
|
*/
|
|
6
6
|
export interface AdaptableComment extends AdaptableObject {
|
|
7
|
+
/**
|
|
8
|
+
* When Comment was made
|
|
9
|
+
*/
|
|
7
10
|
Timestamp: number;
|
|
11
|
+
/**
|
|
12
|
+
* Value of the Comment
|
|
13
|
+
*/
|
|
8
14
|
Value: string;
|
|
15
|
+
/**
|
|
16
|
+
* Author of the Comment
|
|
17
|
+
*/
|
|
9
18
|
Author: {
|
|
10
19
|
UserName: string;
|
|
11
20
|
};
|
|
21
|
+
/**
|
|
22
|
+
* Value in Grid's Primary Key Column
|
|
23
|
+
*/
|
|
12
24
|
PrimaryKeyValue: any;
|
|
25
|
+
/**
|
|
26
|
+
* Id of Column containing the Comment
|
|
27
|
+
*/
|
|
13
28
|
ColumnId: string;
|
|
29
|
+
/**
|
|
30
|
+
* Id of this AdapTable instance
|
|
31
|
+
*/
|
|
14
32
|
AdaptableId: string;
|
|
15
33
|
}
|
|
16
34
|
export declare type AdaptableComments = AdaptableComment[];
|
|
17
35
|
/**
|
|
18
|
-
* Predefined Configuration for
|
|
36
|
+
* Predefined Configuration for Comments Module
|
|
19
37
|
*/
|
|
20
38
|
export interface CommentsState extends ConfigState {
|
|
21
39
|
/**
|
|
22
|
-
* Collection of
|
|
40
|
+
* Collection of AdapTable Comments
|
|
23
41
|
*/
|
|
24
42
|
Comments?: AdaptableComments;
|
|
25
43
|
}
|
|
26
|
-
|
|
44
|
+
/**
|
|
45
|
+
* Cell that contains a Comment
|
|
46
|
+
*/
|
|
47
|
+
export declare type CommentGridCell = {
|
|
48
|
+
/**
|
|
49
|
+
* Value in Primary Key Column
|
|
50
|
+
*/
|
|
27
51
|
PrimaryKeyValue: string | number;
|
|
52
|
+
/**
|
|
53
|
+
* Id of Column containing the Comment
|
|
54
|
+
*/
|
|
28
55
|
ColumnId: string;
|
|
29
56
|
};
|
|
@@ -13,6 +13,6 @@ export interface Entitlement {
|
|
|
13
13
|
accessLevel: AccessLevel;
|
|
14
14
|
}
|
|
15
15
|
/**
|
|
16
|
-
*
|
|
16
|
+
* Whether an Entitlement is `ReadOnly`, `Hidden` or `Full`
|
|
17
17
|
*/
|
|
18
18
|
export declare type AccessLevel = 'ReadOnly' | 'Hidden' | 'Full';
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import { Chart, ChatInitSettings, Contact, ContactList, Context, Country, Currency, Email, Instrument, InstrumentList, Nothing, Organization, Portfolio, Position, TimeRange, Valuation, ContextTypes } from '@finos/fdc3';
|
|
2
|
+
/**
|
|
3
|
+
* FDC3 (2.0) Context Types supported by AdapTable
|
|
4
|
+
*/
|
|
2
5
|
export declare type Fdc3ContextType = ChartContextType | ChatInitSettingsContextType | ContactContextType | ContactListContextType | CountryContextType | CurrencyContextType | EmailContextType | InstrumentContextType | InstrumentListContextType | OrganizationContextType | PortfolioContextType | PositionContextType | TimeRangeContextType | ValuationContextType | NothingContextType;
|
|
3
6
|
export declare type Fdc3CustomContextType = string;
|
|
4
7
|
export declare const ChartContextKey = "fdc3.chart";
|
|
@@ -31,6 +34,9 @@ export declare const ValuationContextKey = "fdc3.valuation";
|
|
|
31
34
|
export declare type ValuationContextType = typeof ValuationContextKey;
|
|
32
35
|
export declare const NothingContextKey = "fdc3.nothing";
|
|
33
36
|
export declare type NothingContextType = typeof NothingContextKey;
|
|
37
|
+
/**
|
|
38
|
+
* FDC3 (2.0) Contexts
|
|
39
|
+
*/
|
|
34
40
|
export declare type Fdc3Context = ChartContext | ChatInitSettingsContext | ContactContext | ContactListContext | CountryContext | CurrencyContext | EmailContext | InstrumentContext | InstrumentListContext | OrganizationContext | PortfolioContext | PositionContext | TimeRangeContext | ValuationContext | NothingContext;
|
|
35
41
|
export declare type Fdc3CustomContext = Context;
|
|
36
42
|
export declare type TypedFdc3Context<CONTEXT, TYPE extends Fdc3ContextType> = CONTEXT & {
|
|
@@ -14,7 +14,7 @@ import { AdaptableFlashingCell } from './Common/AdaptableFlashingCell';
|
|
|
14
14
|
import { TypeUuid } from './Uuid';
|
|
15
15
|
import { SummaryOperation } from './Common/Enums';
|
|
16
16
|
import { ChartModel } from '@ag-grid-community/core';
|
|
17
|
-
import {
|
|
17
|
+
import { CommentGridCell } from './CommentsState';
|
|
18
18
|
export type { IPushPullReport, IPushPullDomain };
|
|
19
19
|
export type { Glue42Report };
|
|
20
20
|
export type { OpenFinReport };
|
|
@@ -100,7 +100,7 @@ export interface SystemState extends InternalState, IPushPullState, Glue42State,
|
|
|
100
100
|
};
|
|
101
101
|
Comments?: {
|
|
102
102
|
editMode?: boolean;
|
|
103
|
-
popupPosition?:
|
|
103
|
+
popupPosition?: CommentGridCell | null;
|
|
104
104
|
};
|
|
105
105
|
}
|
|
106
106
|
export interface ProgressIndicator {
|
|
@@ -14,7 +14,7 @@ import { SummaryOperation } from '../../PredefinedConfig/Common/Enums';
|
|
|
14
14
|
import { CellDataChangedInfo } from '../../PredefinedConfig/Common/CellDataChangedInfo';
|
|
15
15
|
import { RowsHighlightInfo } from '../../PredefinedConfig/Common/RowsHighlightInfo';
|
|
16
16
|
import { SmartEditOperation } from '../../AdaptableOptions/EditOptions';
|
|
17
|
-
import {
|
|
17
|
+
import { CommentGridCell, DataSet } from '../../types';
|
|
18
18
|
import { ChartModel } from '@ag-grid-community/core';
|
|
19
19
|
export declare const FLASHING_CELL_ROW_KEY = "__ROW";
|
|
20
20
|
export declare const SYSTEM_ALERT_ADD = "SYSTEM_ALERT_ADD";
|
|
@@ -256,7 +256,7 @@ export interface SystemQuickSearchFloatingVisibilityAction extends Redux.Action
|
|
|
256
256
|
visible: boolean;
|
|
257
257
|
}
|
|
258
258
|
export interface SystemCommentsShowAction extends Redux.Action {
|
|
259
|
-
cellPosition:
|
|
259
|
+
cellPosition: CommentGridCell;
|
|
260
260
|
editMode?: boolean;
|
|
261
261
|
}
|
|
262
262
|
export interface SystemCommentsHideAction extends Redux.Action {
|
|
@@ -318,11 +318,11 @@ export declare const SystemDisableDeleteConfirmation: () => SystemDisableDeleteC
|
|
|
318
318
|
export declare const SystemVisualExportBegin: () => SystemVisualExportBeginAction;
|
|
319
319
|
export declare const SystemVisualExportEnd: () => SystemVisualExportEndAction;
|
|
320
320
|
export declare const SystemQuickSearchFloatingVisibility: (visible: boolean) => SystemQuickSearchFloatingVisibilityAction;
|
|
321
|
-
export declare const SystemCommentsShow: (cellPosition:
|
|
321
|
+
export declare const SystemCommentsShow: (cellPosition: CommentGridCell, editMode?: boolean) => SystemCommentsShowAction;
|
|
322
322
|
export declare const SystemCommentsHide: () => SystemCommentsHideAction;
|
|
323
323
|
export declare const SystemDisableDeleteConfirmationSelector: (state: SystemState) => boolean;
|
|
324
324
|
export declare const SystemPreviousGroupedColumnsSelector: (state: SystemState) => Record<string, Record<string, number>>;
|
|
325
325
|
export declare const SystemQuickSearchFloatingVisibilitySelector: (state: SystemState) => boolean;
|
|
326
|
-
export declare const SystemCommentsSelector: (state: SystemState) =>
|
|
326
|
+
export declare const SystemCommentsSelector: (state: SystemState) => CommentGridCell;
|
|
327
327
|
export declare const SystemCommentsEditModeSelector: (state: SystemState) => boolean;
|
|
328
328
|
export declare const SystemReducer: Redux.Reducer<SystemState>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AdaptableApi } from '../Api/AdaptableApi';
|
|
2
2
|
import { AdaptableMenuItem, ContextMenuContext } from '../PredefinedConfig/Common/Menu';
|
|
3
|
-
import {
|
|
3
|
+
import { CommentGridCell } from '../types';
|
|
4
4
|
import { AdaptableModuleBase } from './AdaptableModuleBase';
|
|
5
5
|
import { IModule } from './Interface/IModule';
|
|
6
6
|
/**
|
|
@@ -19,5 +19,5 @@ export declare class CommentsModule extends AdaptableModuleBase implements IModu
|
|
|
19
19
|
ColumnId: string;
|
|
20
20
|
};
|
|
21
21
|
handleMouseEnter(event: MouseEvent): void;
|
|
22
|
-
handleCellSelected(
|
|
22
|
+
handleCellSelected(commentGridCell: CommentGridCell): void;
|
|
23
23
|
}
|