@adaptabletools/adaptable 20.0.0-canary.3 → 20.0.0-canary.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/AdaptableInterfaces/IAdaptable.d.ts +2 -1
- package/src/AdaptableOptions/CellSummaryOptions.d.ts +1 -1
- package/src/AdaptableOptions/ContainerOptions.d.ts +0 -7
- package/src/AdaptableOptions/DefaultAdaptableOptions.js +1 -1
- package/src/AdaptableOptions/EditOptions.d.ts +14 -3
- package/src/AdaptableOptions/ExportOptions.d.ts +4 -18
- package/src/AdaptableOptions/PredicateOptions.d.ts +4 -4
- package/src/AdaptableOptions/UserInterfaceOptions.d.ts +7 -0
- package/src/Api/Implementation/AdaptableApiImpl.js +1 -0
- package/src/Api/Implementation/ExportApiImpl.js +3 -2
- package/src/Api/Implementation/ScheduleApiImpl.js +1 -1
- package/src/Api/Implementation/StyledColumnApiImpl.js +1 -1
- package/src/Api/Implementation/ThemeApiImpl.js +3 -1
- package/src/Api/Internal/EventInternalApi.js +6 -1
- package/src/Api/Internal/ExportInternalApi.js +1 -1
- package/src/Api/Internal/RowFormInternalApi.js +1 -1
- package/src/Api/ThemeApi.d.ts +2 -0
- package/src/PredefinedConfig/AlertState.d.ts +1 -1
- package/src/PredefinedConfig/Common/AdaptableColumnContext.d.ts +1 -1
- package/src/PredefinedConfig/Common/AdaptablePredicate.js +0 -16
- package/src/PredefinedConfig/ExportState.d.ts +3 -3
- package/src/PredefinedConfig/FlashingCellState.d.ts +1 -1
- package/src/PredefinedConfig/LayoutState.d.ts +16 -16
- package/src/PredefinedConfig/StyledColumnState.d.ts +1 -1
- package/src/Strategy/StyledColumnModule.js +6 -6
- package/src/Utilities/ObjectFactory.js +1 -0
- package/src/Utilities/Services/ThemeService.d.ts +1 -1
- package/src/Utilities/Services/ThemeService.js +5 -5
- package/src/View/DataChangeHistory/DataChangeHistoryPopup.js +4 -1
- package/src/View/GridInfo/GridInfoPopup/GridInfoPopup.js +7 -2
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsReport.d.ts +2 -0
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsReport.js +18 -2
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsSummary.js +4 -0
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsWizard.js +2 -1
- package/src/View/StyledColumn/Wizard/StyledColumnSparklineSettingsSection.d.ts +3 -4
- package/src/View/StyledColumn/Wizard/StyledColumnSparklineSettingsSection.js +348 -191
- package/src/View/StyledColumn/Wizard/StyledColumnWizard.js +2 -2
- package/src/View/StyledColumn/Wizard/StyledColumnWizardColumnSection.js +1 -1
- package/src/View/StyledColumn/Wizard/StyledColumnWizardTypeSection.js +4 -4
- package/src/agGrid/AdaptableAgGrid.d.ts +3 -8
- package/src/agGrid/AdaptableAgGrid.js +35 -116
- package/src/agGrid/AgGridAdapter.d.ts +1 -1
- package/src/agGrid/AgGridAdapter.js +6 -7
- package/src/agGrid/AgGridColumnAdapter.js +5 -7
- package/src/agGrid/AgGridThemeAdapter.d.ts +19 -0
- package/src/agGrid/AgGridThemeAdapter.js +122 -0
- package/src/components/ColorPicker/ColorPicker.js +2 -2
- package/src/components/OverlayTrigger/useAgGridClassName.js +1 -1
- package/src/env.js +2 -2
- package/src/metamodel/adaptable.metamodel.d.ts +16 -15
- package/src/metamodel/adaptable.metamodel.js +1 -1
- package/src/migration/VersionUpgrade20.d.ts +1 -0
- package/src/migration/VersionUpgrade20.js +69 -0
- package/src/types.d.ts +1 -1
- package/tsconfig.esm.tsbuildinfo +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adaptabletools/adaptable",
|
|
3
|
-
"version": "20.0.0-canary.
|
|
3
|
+
"version": "20.0.0-canary.5",
|
|
4
4
|
"description": "Powerful data-agnostic HTML5 AG Grid extension which provides advanced, cutting-edge functionality to meet all DataGrid requirements",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"web-components",
|
|
@@ -31,6 +31,7 @@ import { AgGridMenuAdapter } from '../agGrid/AgGridMenuAdapter';
|
|
|
31
31
|
import { RowFormService } from '../Utilities/Services/RowFormService';
|
|
32
32
|
import { FlashingCellService } from '../Utilities/Services/FlashingCellService';
|
|
33
33
|
import { AgGridExportAdapter } from '../agGrid/AgGridExportAdapter';
|
|
34
|
+
import { AgGridThemeAdapter } from '../agGrid/AgGridThemeAdapter';
|
|
34
35
|
/**
|
|
35
36
|
* Contains AG Grid Options and Modules - used when instantiating AdapTable vanilla
|
|
36
37
|
*/
|
|
@@ -66,6 +67,7 @@ export interface IAdaptable {
|
|
|
66
67
|
agGridMenuAdapter: AgGridMenuAdapter;
|
|
67
68
|
agGridColumnAdapter: AgGridColumnAdapter;
|
|
68
69
|
agGridExportAdapter: AgGridExportAdapter;
|
|
70
|
+
agGridThemeAdapter: AgGridThemeAdapter;
|
|
69
71
|
hasAdaptableToolPanel: boolean;
|
|
70
72
|
renderReactRoot: RenderReactRootFn;
|
|
71
73
|
/**
|
|
@@ -244,7 +246,6 @@ export interface IAdaptable {
|
|
|
244
246
|
isGridRangeSelectable(): boolean;
|
|
245
247
|
isGridRowSelectable(): boolean;
|
|
246
248
|
isGridGroupingActive(): boolean;
|
|
247
|
-
getAgGridCurrentThemeName(): string;
|
|
248
249
|
applyAdaptableTheme(theme: AdaptableTheme | string): void;
|
|
249
250
|
setRowGroupColumns(columnIds: string[]): void;
|
|
250
251
|
getAllGridColumns(): Column<any>[];
|
|
@@ -9,7 +9,7 @@ export interface CellSummaryOptions<TData = any> {
|
|
|
9
9
|
*/
|
|
10
10
|
customCellSummaryOperations?: CustomCellSummaryOperation<TData>[];
|
|
11
11
|
/**
|
|
12
|
-
* Numeric format to use for summary value;
|
|
12
|
+
* Numeric format to use for summary value; a Format Column DisplayFormat will take precedence
|
|
13
13
|
*/
|
|
14
14
|
numericDisplayFormat?: NumberFormatterOptions | ((columnContext: AdaptableColumnContext) => NumberFormatterOptions);
|
|
15
15
|
}
|
|
@@ -16,13 +16,6 @@ export interface ContainerOptions {
|
|
|
16
16
|
* @gridInfoItem
|
|
17
17
|
*/
|
|
18
18
|
agGridContainer?: string | HTMLElement;
|
|
19
|
-
/**
|
|
20
|
-
* How long to wait for AG Grid before giving up trying to connect
|
|
21
|
-
*
|
|
22
|
-
* @defaultValue 60s
|
|
23
|
-
* @gridInfoItem
|
|
24
|
-
*/
|
|
25
|
-
agGridContainerWaitTimeout?: number;
|
|
26
19
|
/**
|
|
27
20
|
* Name of div where popups appear
|
|
28
21
|
*
|
|
@@ -54,7 +54,6 @@ const DefaultAdaptableOptions = {
|
|
|
54
54
|
containerOptions: {
|
|
55
55
|
adaptableContainer: 'adaptable',
|
|
56
56
|
agGridContainer: 'grid',
|
|
57
|
-
agGridContainerWaitTimeout: 60000,
|
|
58
57
|
modalContainer: undefined,
|
|
59
58
|
systemStatusContainer: undefined,
|
|
60
59
|
alertContainer: undefined,
|
|
@@ -295,6 +294,7 @@ const DefaultAdaptableOptions = {
|
|
|
295
294
|
styleClassNames: EMPTY_ARRAY,
|
|
296
295
|
showDocumentationLinks: true,
|
|
297
296
|
showAdapTableVersion: true,
|
|
297
|
+
showAgGridVersion: true,
|
|
298
298
|
},
|
|
299
299
|
};
|
|
300
300
|
export function applyDefaultAdaptableOptions(adaptableOptions) {
|
|
@@ -26,7 +26,7 @@ export interface EditOptions<TData = any> {
|
|
|
26
26
|
*/
|
|
27
27
|
smartEditCustomOperations?: SmartEditCustomOperation<TData>[];
|
|
28
28
|
/**
|
|
29
|
-
*
|
|
29
|
+
* Columns that will display a Select dropdown when editing
|
|
30
30
|
*/
|
|
31
31
|
showSelectCellEditor?: (currentColumContext: AdaptableColumnContext<TData>) => boolean;
|
|
32
32
|
/**
|
|
@@ -39,17 +39,28 @@ export interface EditOptions<TData = any> {
|
|
|
39
39
|
*/
|
|
40
40
|
export interface CustomEditColumnValuesContext<TData = any> extends AdaptableColumnContext<TData> {
|
|
41
41
|
/**
|
|
42
|
-
* Current distinct values in
|
|
42
|
+
* Current distinct values in Column
|
|
43
43
|
*/
|
|
44
44
|
defaultValues: Required<CustomEditColumnValueInfo>[];
|
|
45
|
+
/**
|
|
46
|
+
* Search text in Edit - used when fetching values from server
|
|
47
|
+
*/
|
|
45
48
|
currentSearchValue: string;
|
|
46
49
|
/**
|
|
47
50
|
* Currently edited Grid Cell
|
|
48
51
|
*/
|
|
49
52
|
gridCell: GridCell;
|
|
50
53
|
}
|
|
54
|
+
/**
|
|
55
|
+
* Information about items in the Edit Controls
|
|
56
|
+
*/
|
|
51
57
|
export interface CustomEditColumnValueInfo {
|
|
52
|
-
|
|
58
|
+
/**
|
|
59
|
+
* Item's label
|
|
60
|
+
*/ label?: string;
|
|
61
|
+
/**
|
|
62
|
+
* Value of Item being shown
|
|
63
|
+
*/
|
|
53
64
|
value: any;
|
|
54
65
|
}
|
|
55
66
|
/**
|
|
@@ -13,7 +13,7 @@ export interface ExportOptions<TData = any> {
|
|
|
13
13
|
*
|
|
14
14
|
* @defaultValue rawValue
|
|
15
15
|
*/
|
|
16
|
-
exportDataFormat?: DataFormatType | DataFormatDataType | ((
|
|
16
|
+
exportDataFormat?: DataFormatType | DataFormatDataType | ((context: AdaptableColumnContext<TData>) => DataFormatType);
|
|
17
17
|
/**
|
|
18
18
|
* Optional custom format for Date columns when exporting
|
|
19
19
|
*
|
|
@@ -66,7 +66,7 @@ export interface ExportOptions<TData = any> {
|
|
|
66
66
|
* Whether a Column is included in System Reports and available in UI for selection
|
|
67
67
|
* @defaultValue true
|
|
68
68
|
*/
|
|
69
|
-
isColumnExportable?: (
|
|
69
|
+
isColumnExportable?: (context: AdaptableColumnContext) => boolean;
|
|
70
70
|
/**
|
|
71
71
|
* Function invoked before a Report is run, enabling users to preload the data before it is exported
|
|
72
72
|
*/
|
|
@@ -257,11 +257,6 @@ export interface ReportContext extends BaseExportContext {
|
|
|
257
257
|
*/
|
|
258
258
|
reportData: ExportResultData;
|
|
259
259
|
}
|
|
260
|
-
/**
|
|
261
|
-
* Context used for setting whether a Column is exportable
|
|
262
|
-
*/
|
|
263
|
-
export interface ExportableColumnContext extends AdaptableColumnContext {
|
|
264
|
-
}
|
|
265
260
|
/**
|
|
266
261
|
* Context used for providing a custom filename for a Report
|
|
267
262
|
*/
|
|
@@ -271,23 +266,14 @@ export interface ReportFileNameContext extends BaseExportContext {
|
|
|
271
266
|
*/
|
|
272
267
|
fileName: string;
|
|
273
268
|
}
|
|
274
|
-
/**
|
|
275
|
-
* Context provided when setting a Data Format Type for Export
|
|
276
|
-
*/
|
|
277
|
-
export interface DataFormatTypeContext<TData = any> extends BaseContext {
|
|
278
|
-
/**
|
|
279
|
-
* Column being exported
|
|
280
|
-
*/
|
|
281
|
-
column: AdaptableColumn<TData>;
|
|
282
|
-
}
|
|
283
269
|
/**
|
|
284
270
|
* Defines the Format Data Types for all Data Types
|
|
285
271
|
*/
|
|
286
272
|
export interface DataFormatDataType {
|
|
287
273
|
/**
|
|
288
|
-
* Data Format type for String columns
|
|
274
|
+
* Data Format type for String / Text columns
|
|
289
275
|
*/
|
|
290
|
-
|
|
276
|
+
text?: DataFormatType;
|
|
291
277
|
/**
|
|
292
278
|
* Data Format type for Number columns
|
|
293
279
|
*/
|
|
@@ -36,10 +36,10 @@ export interface PredicateOptions {
|
|
|
36
36
|
*/
|
|
37
37
|
caseSensitivePredicates?: boolean;
|
|
38
38
|
/**
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
39
|
+
* Should Values (IN) Predicate evaluate using datetime (rather than date)
|
|
40
|
+
* @defaultValue true
|
|
41
|
+
* @noCodeItem
|
|
42
|
+
*/
|
|
43
43
|
evaluateValuesPredicateUsingTime?: boolean;
|
|
44
44
|
}
|
|
45
45
|
/**
|
|
@@ -68,6 +68,13 @@ export interface UserInterfaceOptions<TData = any> {
|
|
|
68
68
|
* @gridInfoItem
|
|
69
69
|
*/
|
|
70
70
|
showAdapTableVersion?: boolean;
|
|
71
|
+
/**
|
|
72
|
+
* Displays the AG Grid version in Grid Info section of Settings Panel
|
|
73
|
+
*
|
|
74
|
+
* @defaultValue true
|
|
75
|
+
* @gridInfoItem
|
|
76
|
+
*/
|
|
77
|
+
showAgGridVersion?: boolean;
|
|
71
78
|
/**
|
|
72
79
|
* English variant to use in AdapTable UI
|
|
73
80
|
*
|
|
@@ -143,10 +143,11 @@ export class ExportApiImpl extends ApiBase {
|
|
|
143
143
|
isColumnExportable(adaptableColumn) {
|
|
144
144
|
const isExportableFn = this.getExportOptions().isColumnExportable;
|
|
145
145
|
if (typeof isExportableFn === 'function') {
|
|
146
|
-
|
|
146
|
+
const adaptableColumnContext = {
|
|
147
147
|
...this.getAdaptableInternalApi().buildBaseContext(),
|
|
148
148
|
column: adaptableColumn,
|
|
149
|
-
}
|
|
149
|
+
};
|
|
150
|
+
return isExportableFn(adaptableColumnContext);
|
|
150
151
|
}
|
|
151
152
|
return true;
|
|
152
153
|
}
|
|
@@ -159,7 +159,7 @@ export class ScheduleApiImpl extends ApiBase {
|
|
|
159
159
|
}
|
|
160
160
|
else if (scheduleType == 'Report') {
|
|
161
161
|
const reportSchedule = schedule;
|
|
162
|
-
this.getExportApi().exportReport(reportSchedule.ReportName, reportSchedule.ReportFormat, 'Download');
|
|
162
|
+
this.getExportApi().exportReport(reportSchedule.ReportName, reportSchedule.ReportFormat, reportSchedule.ExportDestination ?? 'Download');
|
|
163
163
|
}
|
|
164
164
|
else if (scheduleType == 'ipushpull') {
|
|
165
165
|
const ippApi = this.getAdaptableApi().pluginsApi.getipushpullPluginApi();
|
|
@@ -35,7 +35,7 @@ export class StyledColumnApiImpl extends ApiBase {
|
|
|
35
35
|
if (!column) {
|
|
36
36
|
return false;
|
|
37
37
|
}
|
|
38
|
-
return !!this.getStyledColumns().find((styledColumn) => !!styledColumn.
|
|
38
|
+
return !!this.getStyledColumns().find((styledColumn) => !!styledColumn.SparklineStyle && styledColumn.ColumnId === column.columnId);
|
|
39
39
|
}
|
|
40
40
|
getActiveStyledColumnForColumn(column) {
|
|
41
41
|
const styledColumns = this.getActiveStyledColumns();
|
|
@@ -4,6 +4,7 @@ import { ApiBase } from './ApiBase';
|
|
|
4
4
|
import { StaticThemes } from '../../themes';
|
|
5
5
|
import { ThemeInternalApi } from '../Internal/ThemeInternalApi';
|
|
6
6
|
import AdaptableHelper from '../../Utilities/Helpers/AdaptableHelper';
|
|
7
|
+
import { logDeprecation } from '../../Utilities/logDeprecation';
|
|
7
8
|
export class ThemeApiImpl extends ApiBase {
|
|
8
9
|
constructor(_adaptable) {
|
|
9
10
|
super(_adaptable);
|
|
@@ -70,7 +71,8 @@ export class ThemeApiImpl extends ApiBase {
|
|
|
70
71
|
this.showModulePopup(ModuleConstants.ThemeModuleId);
|
|
71
72
|
}
|
|
72
73
|
getAgGridCurrentThemeName() {
|
|
73
|
-
|
|
74
|
+
logDeprecation(this._adaptable.logger, 'ThemeApi', 'getAgGridCurrentThemeName', null, `This is required only for AG Grid's legacy themes. See https://www.ag-grid.com/javascript-data-grid/theming-v32/`);
|
|
75
|
+
return this._adaptable.agGridThemeAdapter.getAgGridCurrentThemeClassNames();
|
|
74
76
|
}
|
|
75
77
|
editTheme(theme) {
|
|
76
78
|
this.dispatchAction(ThemeRedux.ThemeEdit(theme));
|
|
@@ -59,7 +59,12 @@ export class EventInternalApi extends ApiBase {
|
|
|
59
59
|
isToolbarStateChangedToHidden,
|
|
60
60
|
};
|
|
61
61
|
if (!isEqual(oldDashboardState, newDashboardState)) {
|
|
62
|
-
setTimeout(() =>
|
|
62
|
+
setTimeout(() => {
|
|
63
|
+
const eventApi = this.getEventApi();
|
|
64
|
+
if (eventApi) {
|
|
65
|
+
eventApi.emit('DashboardChanged', dashboardChangedInfo);
|
|
66
|
+
}
|
|
67
|
+
});
|
|
63
68
|
}
|
|
64
69
|
}
|
|
65
70
|
fireAlertFiredEvent(alertToFire) {
|
|
@@ -113,7 +113,7 @@ export class ExportInternalApi extends ApiBase {
|
|
|
113
113
|
// format is customized based on column data type
|
|
114
114
|
switch (columnDataType) {
|
|
115
115
|
case 'text':
|
|
116
|
-
return dataFormatDataType.
|
|
116
|
+
return dataFormatDataType.text;
|
|
117
117
|
case 'number':
|
|
118
118
|
return dataFormatDataType.number;
|
|
119
119
|
case 'date':
|
|
@@ -187,7 +187,7 @@ export class RowFormInternalApi extends ApiBase {
|
|
|
187
187
|
}
|
|
188
188
|
const returnValues = this.getGridApi().internalApi.getDistinctDisplayValuesForColumnOld(column.columnId);
|
|
189
189
|
// FIXME add support for asynchronous custom select cell editor values
|
|
190
|
-
// it involves refactoring the AdaptableForm &
|
|
190
|
+
// it involves refactoring the AdaptableForm & adaptableFormComponent
|
|
191
191
|
// await this.getSelectCellEditorValuesForColumn(
|
|
192
192
|
// column,
|
|
193
193
|
// gridCell
|
package/src/Api/ThemeApi.d.ts
CHANGED
|
@@ -81,6 +81,8 @@ export interface ThemeApi {
|
|
|
81
81
|
openThemeSettingsPanel(): void;
|
|
82
82
|
/**
|
|
83
83
|
* Get the name of the current AG Grid theme
|
|
84
|
+
*
|
|
85
|
+
* @deprecated required only for legacy AG Grid themes, see https://www.ag-grid.com/javascript-data-grid/theming-v32/
|
|
84
86
|
*/
|
|
85
87
|
getAgGridCurrentThemeName(): string;
|
|
86
88
|
}
|
|
@@ -150,4 +150,4 @@ export type SystemAlertPredicateIds = SystemAlertPredicateId[];
|
|
|
150
150
|
/**
|
|
151
151
|
* List of System Predicates available for Alerts
|
|
152
152
|
*/
|
|
153
|
-
export type SystemAlertPredicateId = 'Blanks' | 'NonBlanks' | 'Equals' | 'NotEquals' | 'GreaterThan' | 'LessThan' | 'Positive' | 'Negative' | 'Zero' | 'Between' | 'NotBetween' | 'Is' | 'IsNot' | 'Contains' | 'NotContains' | 'StartsWith' | 'EndsWith' | 'Regex' | 'Today' | 'Yesterday' | 'Tomorrow' | 'ThisWeek' | 'ThisMonth' | 'ThisQuarter' | 'ThisYear' | 'InPast' | 'InFuture' | 'Before' | 'After' | 'On' | 'NotOn' | 'NextWorkDay' | 'LastWorkDay' | 'WorkDay' | 'Holiday' | 'True' | 'False' | 'PercentChange' | '
|
|
153
|
+
export type SystemAlertPredicateId = 'Blanks' | 'NonBlanks' | 'Equals' | 'NotEquals' | 'GreaterThan' | 'LessThan' | 'Positive' | 'Negative' | 'Zero' | 'Between' | 'NotBetween' | 'Is' | 'IsNot' | 'Contains' | 'NotContains' | 'StartsWith' | 'EndsWith' | 'Regex' | 'Today' | 'Yesterday' | 'Tomorrow' | 'ThisWeek' | 'ThisMonth' | 'ThisQuarter' | 'ThisYear' | 'InPast' | 'InFuture' | 'Before' | 'After' | 'On' | 'NotOn' | 'NextWorkDay' | 'LastWorkDay' | 'WorkDay' | 'Holiday' | 'True' | 'False' | 'PercentChange' | 'In' | 'NotIn' | 'AnyChange';
|
|
@@ -266,22 +266,6 @@ export const SystemPredicateDefs = [
|
|
|
266
266
|
toString: ({ inputs }) => `Not Between ${inputs[0] ?? ''}:${inputs[1]}`,
|
|
267
267
|
shortcuts: ['!:'],
|
|
268
268
|
},
|
|
269
|
-
{
|
|
270
|
-
id: 'IsNumeric',
|
|
271
|
-
label: 'Is Numeric',
|
|
272
|
-
icon: { text: '1' },
|
|
273
|
-
columnScope: { DataTypes: ['number'] },
|
|
274
|
-
moduleScope: ['alert', 'flashingcell'],
|
|
275
|
-
handler: ({ value }) => !isNaN(Number(value)),
|
|
276
|
-
},
|
|
277
|
-
{
|
|
278
|
-
id: 'IsNotNumeric',
|
|
279
|
-
label: 'Is Not Numeric',
|
|
280
|
-
icon: { text: '1' },
|
|
281
|
-
columnScope: { DataTypes: ['number'] },
|
|
282
|
-
moduleScope: ['alert', 'flashingcell'],
|
|
283
|
-
handler: ({ value }) => isNaN(Number(value)),
|
|
284
|
-
},
|
|
285
269
|
// String System Filters
|
|
286
270
|
{
|
|
287
271
|
id: 'Is',
|
|
@@ -3,9 +3,9 @@ import { BaseSchedule } from './Common/Schedule';
|
|
|
3
3
|
import { ColumnScope } from './Common/ColumnScope';
|
|
4
4
|
import { AdaptableColumnBase } from './Common/AdaptableColumn';
|
|
5
5
|
import { AdaptableObject } from './Common/AdaptableObject';
|
|
6
|
-
import { AdaptableFormData } from './Common/AdaptableForm';
|
|
7
6
|
import { AdaptableBooleanQuery } from './Common/AdaptableQuery';
|
|
8
7
|
import { TypeHint } from './Common/Types';
|
|
8
|
+
import { ExportDestinationType } from '../AdaptableOptions/ExportOptions';
|
|
9
9
|
/**
|
|
10
10
|
* Predefined Configuration for Export Module
|
|
11
11
|
*/
|
|
@@ -61,9 +61,9 @@ export interface ReportSchedule extends BaseSchedule {
|
|
|
61
61
|
*/
|
|
62
62
|
ReportFormat: ReportFormatType;
|
|
63
63
|
/**
|
|
64
|
-
*
|
|
64
|
+
* Destination of Report to run on Schedule
|
|
65
65
|
*/
|
|
66
|
-
|
|
66
|
+
ExportDestination?: ExportDestinationType;
|
|
67
67
|
}
|
|
68
68
|
/**
|
|
69
69
|
* Defines the data in a Report run by AdapTable
|
|
@@ -72,4 +72,4 @@ export type SystemFlashingCellPredicateIds = SystemFlashingCellPredicateId[];
|
|
|
72
72
|
/**
|
|
73
73
|
* List of System Predicates available for Flashing Cells
|
|
74
74
|
*/
|
|
75
|
-
export type SystemFlashingCellPredicateId = 'Blanks' | 'NonBlanks' | 'Equals' | 'NotEquals' | 'GreaterThan' | 'LessThan' | 'Positive' | 'Negative' | 'Zero' | 'Between' | 'NotBetween' | 'Is' | 'IsNot' | 'Contains' | 'NotContains' | 'StartsWith' | 'EndsWith' | 'Regex' | 'Today' | 'Yesterday' | 'Tomorrow' | 'ThisWeek' | 'ThisMonth' | 'ThisQuarter' | 'ThisYear' | 'InPast' | 'InFuture' | 'Before' | 'After' | 'On' | 'NotOn' | 'NextWorkDay' | 'LastWorkDay' | 'WorkDay' | 'Holiday' | 'True' | 'False' | 'PercentChange' | '
|
|
75
|
+
export type SystemFlashingCellPredicateId = 'Blanks' | 'NonBlanks' | 'Equals' | 'NotEquals' | 'GreaterThan' | 'LessThan' | 'Positive' | 'Negative' | 'Zero' | 'Between' | 'NotBetween' | 'Is' | 'IsNot' | 'Contains' | 'NotContains' | 'StartsWith' | 'EndsWith' | 'Regex' | 'Today' | 'Yesterday' | 'Tomorrow' | 'ThisWeek' | 'ThisMonth' | 'ThisQuarter' | 'ThisYear' | 'InPast' | 'InFuture' | 'Before' | 'After' | 'On' | 'NotOn' | 'NextWorkDay' | 'LastWorkDay' | 'WorkDay' | 'Holiday' | 'True' | 'False' | 'PercentChange' | 'In' | 'NotIn' | 'AnyChange';
|
|
@@ -51,7 +51,7 @@ export interface LayoutBase extends AdaptableObject {
|
|
|
51
51
|
*/
|
|
52
52
|
ColumnHeaders?: ColumnStringMap;
|
|
53
53
|
/**
|
|
54
|
-
* Whether to include aggFunc name in
|
|
54
|
+
* Whether to include aggFunc name in Column header: e.g. 'sum(Price)' becomes 'Price'
|
|
55
55
|
*/
|
|
56
56
|
SuppressAggFuncInHeader?: boolean;
|
|
57
57
|
/**
|
|
@@ -88,7 +88,7 @@ export interface TableLayout extends LayoutBase {
|
|
|
88
88
|
*/
|
|
89
89
|
RowSummaries?: RowSummary[];
|
|
90
90
|
/**
|
|
91
|
-
* Columns showing aggregated values in
|
|
91
|
+
* Columns showing aggregated values in Grouped Rows; a record of ColumnId and aggfunc (e.g. sum) or 'true' (to use default aggfunc)
|
|
92
92
|
*/
|
|
93
93
|
TableAggregationColumns?: TableAggregationColumns;
|
|
94
94
|
/**
|
|
@@ -100,19 +100,19 @@ export interface TableLayout extends LayoutBase {
|
|
|
100
100
|
*/
|
|
101
101
|
RowGroupDisplayType?: 'single' | 'multi';
|
|
102
102
|
/**
|
|
103
|
-
* Pivot Columns -
|
|
103
|
+
* Pivot Columns - must NOT be provided
|
|
104
104
|
*/
|
|
105
105
|
PivotColumns?: never;
|
|
106
106
|
/**
|
|
107
|
-
* Pivot Group Columns -
|
|
107
|
+
* Pivot Group Columns - must NOT be provided
|
|
108
108
|
*/
|
|
109
109
|
PivotGroupedColumns?: never;
|
|
110
110
|
/**
|
|
111
|
-
* Pivot Expansions -
|
|
111
|
+
* Pivot Expansions - must NOT be provided
|
|
112
112
|
*/
|
|
113
113
|
PivotExpandLevel?: never;
|
|
114
114
|
/**
|
|
115
|
-
* Pivot Aggregation Columns -
|
|
115
|
+
* Pivot Aggregation Columns - must NOT be provided
|
|
116
116
|
*/
|
|
117
117
|
PivotAggregationColumns?: never;
|
|
118
118
|
}
|
|
@@ -137,31 +137,31 @@ export interface PivotLayout extends LayoutBase {
|
|
|
137
137
|
*/
|
|
138
138
|
PivotGroupedColumns?: string[];
|
|
139
139
|
/**
|
|
140
|
-
* Table Columns -
|
|
140
|
+
* Table Columns - must NOT be provided
|
|
141
141
|
*/
|
|
142
142
|
TableColumns?: never;
|
|
143
143
|
/**
|
|
144
|
-
* Table Aggregation Columns -
|
|
144
|
+
* Table Aggregation Columns - must NOT be provided
|
|
145
145
|
*/
|
|
146
146
|
TableAggregationColumns?: never;
|
|
147
147
|
/**
|
|
148
|
-
* Row Grouped Columns Columns -
|
|
148
|
+
* Row Grouped Columns Columns - must NOT be provided
|
|
149
149
|
*/
|
|
150
150
|
RowGroupedColumns?: never;
|
|
151
151
|
}
|
|
152
|
-
/**
|
|
153
|
-
* Object used for defining which Row Group Values are Expanded or Collapsed
|
|
154
|
-
*/
|
|
155
|
-
export type RowGroupValuesWithExceptionKeys = {
|
|
156
|
-
RowGroupDefaultBehavior: 'expanded' | 'collapsed';
|
|
157
|
-
ExceptionGroupKeys?: any[][];
|
|
158
|
-
};
|
|
159
152
|
/**
|
|
160
153
|
* Manages how (and which) Row Group values are stored
|
|
161
154
|
*/
|
|
162
155
|
export type RowGroupValues = {
|
|
163
156
|
RowGroupDefaultBehavior: 'always-expanded' | 'always-collapsed';
|
|
164
157
|
} | RowGroupValuesWithExceptionKeys;
|
|
158
|
+
/**
|
|
159
|
+
* Defines which Row Group Values are expanded or collapsed
|
|
160
|
+
*/
|
|
161
|
+
export type RowGroupValuesWithExceptionKeys = {
|
|
162
|
+
RowGroupDefaultBehavior: 'expanded' | 'collapsed';
|
|
163
|
+
ExceptionGroupKeys?: any[][];
|
|
164
|
+
};
|
|
165
165
|
/**
|
|
166
166
|
* Defines a map of Columns with a String value
|
|
167
167
|
*/
|
|
@@ -35,12 +35,12 @@ export class StyledColumnModule extends AdaptableModuleBase {
|
|
|
35
35
|
// because if just one then it was created in AG Grid and we dont want to edit it
|
|
36
36
|
}
|
|
37
37
|
else {
|
|
38
|
-
const hasSparklineStyle = styledColumn != null && styledColumn.
|
|
38
|
+
const hasSparklineStyle = styledColumn != null && styledColumn.SparklineStyle != null;
|
|
39
39
|
if (!hasSparklineStyle) {
|
|
40
40
|
styledColumn = {
|
|
41
41
|
...ObjectFactory.CreateEmptyStyledColumn(),
|
|
42
42
|
ColumnId: column.columnId,
|
|
43
|
-
|
|
43
|
+
SparklineStyle: {},
|
|
44
44
|
};
|
|
45
45
|
}
|
|
46
46
|
let label = hasSparklineStyle ? 'Edit ' : 'Create ';
|
|
@@ -48,7 +48,7 @@ export class StyledColumnModule extends AdaptableModuleBase {
|
|
|
48
48
|
? 'styled-column-sparkline-edit'
|
|
49
49
|
: 'styled-column-sparkline-add';
|
|
50
50
|
let popupParam = {
|
|
51
|
-
action:
|
|
51
|
+
action: hasSparklineStyle ? 'Edit' : 'New',
|
|
52
52
|
source: 'ColumnMenu',
|
|
53
53
|
value: styledColumn,
|
|
54
54
|
config: {
|
|
@@ -161,7 +161,7 @@ export class StyledColumnModule extends AdaptableModuleBase {
|
|
|
161
161
|
else if (styledColumn.PercentBarStyle) {
|
|
162
162
|
return 'percent';
|
|
163
163
|
}
|
|
164
|
-
else if (styledColumn.
|
|
164
|
+
else if (styledColumn.SparklineStyle) {
|
|
165
165
|
return 'spark-line';
|
|
166
166
|
}
|
|
167
167
|
else if (styledColumn.BadgeStyle) {
|
|
@@ -248,7 +248,7 @@ export class StyledColumnModule extends AdaptableModuleBase {
|
|
|
248
248
|
else if (styledColumn.PercentBarStyle) {
|
|
249
249
|
type = 'Percent Bar';
|
|
250
250
|
}
|
|
251
|
-
else if (styledColumn.
|
|
251
|
+
else if (styledColumn.SparklineStyle) {
|
|
252
252
|
type = 'Spark Line';
|
|
253
253
|
}
|
|
254
254
|
else if (styledColumn.BadgeStyle) {
|
|
@@ -264,7 +264,7 @@ export class StyledColumnModule extends AdaptableModuleBase {
|
|
|
264
264
|
else if (styledColumn.PercentBarStyle) {
|
|
265
265
|
type = 'styled-column-percent-bar-edit';
|
|
266
266
|
}
|
|
267
|
-
else if (styledColumn.
|
|
267
|
+
else if (styledColumn.SparklineStyle) {
|
|
268
268
|
type = 'styled-column-sparkline-edit';
|
|
269
269
|
}
|
|
270
270
|
else if (styledColumn.BadgeStyle) {
|
|
@@ -5,10 +5,10 @@ export declare class ThemeService implements IThemeService {
|
|
|
5
5
|
private unsubscribe;
|
|
6
6
|
private styleSheetObject;
|
|
7
7
|
constructor(api: AdaptableApi);
|
|
8
|
+
destroy(): void;
|
|
8
9
|
subscribe(): void;
|
|
9
10
|
onThemeChanged: () => void;
|
|
10
11
|
applyNewThemeVariables(theme: AdaptableTheme): void;
|
|
11
|
-
destroy(): void;
|
|
12
12
|
showMissingThemeFiles(theme: AdaptableTheme): void;
|
|
13
13
|
getDOMPrefferedColorScheme(): 'dark' | 'light';
|
|
14
14
|
mapOsTheme(theme: AdaptableTheme | string): AdaptableTheme;
|
|
@@ -20,6 +20,11 @@ export class ThemeService {
|
|
|
20
20
|
];
|
|
21
21
|
}
|
|
22
22
|
}
|
|
23
|
+
destroy() {
|
|
24
|
+
this.api = null;
|
|
25
|
+
this.unsubscribe();
|
|
26
|
+
document.adoptedStyleSheets = [...document.adoptedStyleSheets].filter((sheet) => sheet !== this.styleSheetObject);
|
|
27
|
+
}
|
|
23
28
|
subscribe() {
|
|
24
29
|
const themeChangedUnsubscribe = this.api.eventApi.on('ThemeChanged', this.onThemeChanged);
|
|
25
30
|
const prefferedColorSchemeUnsubscribe = this.attachPrefferedColorSchemeListener();
|
|
@@ -44,11 +49,6 @@ export class ThemeService {
|
|
|
44
49
|
str += '}';
|
|
45
50
|
this.styleSheetObject.replaceSync(str);
|
|
46
51
|
}
|
|
47
|
-
destroy() {
|
|
48
|
-
this.api = null;
|
|
49
|
-
this.unsubscribe();
|
|
50
|
-
document.adoptedStyleSheets = [...document.adoptedStyleSheets].filter((sheet) => sheet !== this.styleSheetObject);
|
|
51
|
-
}
|
|
52
52
|
showMissingThemeFiles(theme) {
|
|
53
53
|
// run time defined theme
|
|
54
54
|
// because it may be an empty theme
|
|
@@ -54,7 +54,10 @@ class DataChangeHistoryPopupComponent extends React.Component {
|
|
|
54
54
|
this.props.api.dataChangeHistoryApi.clearDataChangeHistoryEntry(changeToBeUndone);
|
|
55
55
|
}
|
|
56
56
|
};
|
|
57
|
-
const
|
|
57
|
+
const agGridThemeMode = this.props.api.internalApi
|
|
58
|
+
.getAdaptableInstance()
|
|
59
|
+
.agGridThemeAdapter.getAgGridThemeMode();
|
|
60
|
+
const currentAgGridTheme = agGridThemeMode === 'legacy' ? this.props.api.themeApi.getAgGridCurrentThemeName() : '';
|
|
58
61
|
return (React.createElement(PopupPanel, { headerText: this.props.moduleInfo.FriendlyName, glyphicon: this.props.moduleInfo.Glyph, infoLink: this.props.moduleInfo.HelpPage, infoLinkDisabled: !this.props.api.internalApi.isDocumentationLinksDisplayed() },
|
|
59
62
|
React.createElement(Flex, { className: "ab-DataChangeHistoryPopup", flexDirection: "column", style: { height: '100%' } },
|
|
60
63
|
React.createElement(Flex, { style: {
|
|
@@ -10,7 +10,9 @@ import { AdaptableObjectRow } from '../../Components/AdaptableObjectRow';
|
|
|
10
10
|
import { PopupPanel } from '../../Components/Popups/AdaptablePopup/PopupPanel';
|
|
11
11
|
import { AdaptableObjectsSummary } from './AdaptableObjectsSummary';
|
|
12
12
|
import { ADAPTABLE_VERSION } from '../../../EnvVars';
|
|
13
|
-
|
|
13
|
+
import { AG_GRID_VERSION } from '../../../agGrid/agGridModules';
|
|
14
|
+
const adaptableVersion = ADAPTABLE_VERSION;
|
|
15
|
+
const agGridVersion = AG_GRID_VERSION;
|
|
14
16
|
export const GridInfoPopup = (props) => {
|
|
15
17
|
const api = props.api;
|
|
16
18
|
const CreateGridSummaries = (colItems) => {
|
|
@@ -33,7 +35,10 @@ export const GridInfoPopup = (props) => {
|
|
|
33
35
|
: null;
|
|
34
36
|
const selectedRowInfo = api.gridApi.getSelectedRowInfo();
|
|
35
37
|
if (api.optionsApi.getUserInterfaceOptions()?.showAdapTableVersion) {
|
|
36
|
-
returnRows.push(createReadOnlyColItem(colItems, 'AdapTable Version',
|
|
38
|
+
returnRows.push(createReadOnlyColItem(colItems, 'AdapTable Version', adaptableVersion));
|
|
39
|
+
}
|
|
40
|
+
if (api.optionsApi.getUserInterfaceOptions()?.showAgGridVersion) {
|
|
41
|
+
returnRows.push(createReadOnlyColItem(colItems, 'AG Grid Version', agGridVersion));
|
|
37
42
|
}
|
|
38
43
|
returnRows.push(createReadOnlyColItem(colItems, 'Sorted Columns', ArrayExtensions.IsNotNullOrEmpty(sorts) ? sorts.join('; ') : 'None'));
|
|
39
44
|
returnRows.push(createReadOnlyColItem(colItems, 'Column Filters', columnFilterDescription));
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
import { ExportDestinationType } from '../../../../AdaptableOptions/ExportOptions';
|
|
2
3
|
import { Report, ReportFormatType, ReportSchedule } from '../../../../PredefinedConfig/ExportState';
|
|
3
4
|
interface ReportScheduleProps {
|
|
4
5
|
report: ReportSchedule;
|
|
5
6
|
onChange: (reminder: ReportSchedule) => void;
|
|
6
7
|
allReports: Report[];
|
|
7
8
|
allFormats: ReportFormatType[];
|
|
9
|
+
allDestinations: ExportDestinationType[];
|
|
8
10
|
}
|
|
9
11
|
export declare const ScheduleSettingsReport: React.FunctionComponent<ReportScheduleProps>;
|
|
10
12
|
export {};
|