@sap-ux/preview-middleware 0.19.37 → 0.19.39

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.
Files changed (79) hide show
  1. package/dist/client/adp/add-fragment.js +46 -46
  2. package/dist/client/adp/api-handler.js +159 -159
  3. package/dist/client/adp/command-executor.js +75 -75
  4. package/dist/client/adp/control-utils.js +44 -44
  5. package/dist/client/adp/controllers/AddTableColumnFragments.controller.js +5 -10
  6. package/dist/client/adp/controllers/AddTableColumnFragments.controller.ts +3 -9
  7. package/dist/client/adp/controllers/ControllerExtension.controller.js +210 -210
  8. package/dist/client/adp/controllers/ExtensionPoint.controller.js +139 -139
  9. package/dist/client/adp/controllers/FileExistsDialog.controller.js +66 -66
  10. package/dist/client/adp/dialog-factory.js +135 -135
  11. package/dist/client/adp/init-dialogs.js +163 -163
  12. package/dist/client/adp/quick-actions/add-new-subpage-quick-action-base.js +96 -96
  13. package/dist/client/adp/quick-actions/common/add-controller-to-page.js +60 -60
  14. package/dist/client/adp/quick-actions/common/create-page-action.js +54 -54
  15. package/dist/client/adp/quick-actions/common/op-add-custom-section.js +39 -39
  16. package/dist/client/adp/quick-actions/common/op-add-header-field.js +67 -67
  17. package/dist/client/adp/quick-actions/common/utils.js +18 -18
  18. package/dist/client/adp/quick-actions/control-types.js +23 -23
  19. package/dist/client/adp/quick-actions/dialog-enablement-validator.js +24 -24
  20. package/dist/client/adp/quick-actions/enablement-validator.js +4 -4
  21. package/dist/client/adp/quick-actions/fe-v2/add-new-subpage.js +81 -81
  22. package/dist/client/adp/quick-actions/fe-v2/change-table-actions.js +67 -67
  23. package/dist/client/adp/quick-actions/fe-v2/change-table-columns.js +101 -101
  24. package/dist/client/adp/quick-actions/fe-v2/create-table-action.js +107 -107
  25. package/dist/client/adp/quick-actions/fe-v2/create-table-custom-column.js +99 -99
  26. package/dist/client/adp/quick-actions/fe-v2/lr-enable-semantic-date-range-filter-bar.js +78 -78
  27. package/dist/client/adp/quick-actions/fe-v2/lr-enable-table-filtering.js +77 -77
  28. package/dist/client/adp/quick-actions/fe-v2/lr-enable-variant-management.js +69 -69
  29. package/dist/client/adp/quick-actions/fe-v2/lr-toggle-clear-filter-bar.js +59 -59
  30. package/dist/client/adp/quick-actions/fe-v2/op-enable-empty-row-mode.js +93 -93
  31. package/dist/client/adp/quick-actions/fe-v2/op-enable-variant-management.js +84 -84
  32. package/dist/client/adp/quick-actions/fe-v2/registry.js +77 -77
  33. package/dist/client/adp/quick-actions/fe-v2/utils.js +116 -116
  34. package/dist/client/adp/quick-actions/fe-v4/add-new-subpage.js +138 -138
  35. package/dist/client/adp/quick-actions/fe-v4/change-table-actions.js +79 -79
  36. package/dist/client/adp/quick-actions/fe-v4/change-table-columns.js +75 -75
  37. package/dist/client/adp/quick-actions/fe-v4/create-table-action.js +53 -53
  38. package/dist/client/adp/quick-actions/fe-v4/create-table-custom-column.js +49 -49
  39. package/dist/client/adp/quick-actions/fe-v4/enable-variant-management.js +81 -81
  40. package/dist/client/adp/quick-actions/fe-v4/lr-enable-semantic-date-range-filter-bar.js +56 -56
  41. package/dist/client/adp/quick-actions/fe-v4/lr-enable-table-filtering.js +84 -84
  42. package/dist/client/adp/quick-actions/fe-v4/lr-toggle-clear-filter-bar.js +53 -53
  43. package/dist/client/adp/quick-actions/fe-v4/op-enable-empty-row-mode.js +89 -89
  44. package/dist/client/adp/quick-actions/fe-v4/registry.js +60 -60
  45. package/dist/client/adp/quick-actions/fe-v4/utils.js +72 -72
  46. package/dist/client/adp/quick-actions/load.js +44 -44
  47. package/dist/client/adp/quick-actions/quick-action-base.js +64 -64
  48. package/dist/client/adp/utils.js +218 -218
  49. package/dist/client/cpe/additional-change-info/add-xml-additional-info.js +75 -75
  50. package/dist/client/cpe/changes/index.js +10 -10
  51. package/dist/client/cpe/changes/validator.js +39 -39
  52. package/dist/client/cpe/documentation.js +164 -164
  53. package/dist/client/cpe/feature-service.js +36 -36
  54. package/dist/client/cpe/logger.js +30 -30
  55. package/dist/client/cpe/outline/editable.js +37 -37
  56. package/dist/client/cpe/outline/nodes.js +203 -203
  57. package/dist/client/cpe/quick-actions/quick-action-definition.js +4 -4
  58. package/dist/client/cpe/quick-actions/registry.js +143 -143
  59. package/dist/client/cpe/quick-actions/utils.js +92 -92
  60. package/dist/client/cpe/types.js +4 -4
  61. package/dist/client/cpe/ui5-utils.js +33 -33
  62. package/dist/client/cpe/utils.js +111 -111
  63. package/dist/client/flp/WorkspaceConnector.js +92 -92
  64. package/dist/client/flp/common.js +28 -28
  65. package/dist/client/flp/enableFakeConnector.js +89 -89
  66. package/dist/client/flp/homepage/Component.js +14 -14
  67. package/dist/client/flp/initCdm.js +117 -117
  68. package/dist/client/flp/initConnectors.js +28 -28
  69. package/dist/client/flp/initRta.js +178 -178
  70. package/dist/client/i18n.js +56 -56
  71. package/dist/client/utils/additional-change-info.js +54 -41
  72. package/dist/client/utils/additional-change-info.ts +22 -8
  73. package/dist/client/utils/application.js +32 -32
  74. package/dist/client/utils/core.js +84 -84
  75. package/dist/client/utils/error.js +19 -19
  76. package/dist/client/utils/fe-v2.js +56 -56
  77. package/dist/client/utils/fe-v4.js +140 -140
  78. package/dist/client/utils/version.js +104 -104
  79. package/package.json +4 -4
@@ -1,81 +1,81 @@
1
- "use strict";
2
-
3
- sap.ui.define(["sap/ui/dt/OverlayUtil", "../../../utils/core", "../table-quick-action-base", "../control-types", "../../../cpe/quick-actions/utils", "../fe-v2/create-table-custom-column", "../dialog-enablement-validator"], function (OverlayUtil, _____utils_core, ___table_quick_action_base, ___control_types, _____cpe_quick_actions_utils, ___fe_v2_create_table_custom_column, ___dialog_enablement_validator) {
4
- "use strict";
5
-
6
- const getControlById = _____utils_core["getControlById"];
7
- const findNestedElements = _____utils_core["findNestedElements"];
8
- const TableQuickActionDefinitionBase = ___table_quick_action_base["TableQuickActionDefinitionBase"];
9
- const MDC_ACTION_TOOLBAR_TYPE = ___control_types["MDC_ACTION_TOOLBAR_TYPE"];
10
- const MDC_TABLE_TYPE = ___control_types["MDC_TABLE_TYPE"];
11
- const getRelevantControlFromActivePage = _____cpe_quick_actions_utils["getRelevantControlFromActivePage"];
12
- const preprocessActionExecution = ___fe_v2_create_table_custom_column["preprocessActionExecution"];
13
- const DIALOG_ENABLEMENT_VALIDATOR = ___dialog_enablement_validator["DIALOG_ENABLEMENT_VALIDATOR"];
14
- const CHANGE_TABLE_ACTIONS = 'change-table-actions';
15
- const ACTION_ID = 'CTX_SETTINGS';
16
-
17
- /**
18
- * Quick Action for changing table columns.
19
- */
20
- class ChangeTableActionsQuickAction extends TableQuickActionDefinitionBase {
21
- toolbarsMap = {};
22
- constructor(context) {
23
- super(CHANGE_TABLE_ACTIONS, [MDC_TABLE_TYPE], 'V4_QUICK_ACTION_CHANGE_TABLE_ACTIONS', context, undefined, [DIALOG_ENABLEMENT_VALIDATOR]);
24
- }
25
- async initialize() {
26
- const toolbars = getRelevantControlFromActivePage(this.context.controlIndex, this.context.view, [MDC_ACTION_TOOLBAR_TYPE]);
27
- const processChild = async (child, mapKey) => {
28
- const mapEntry = this.tableMap[mapKey];
29
- if (mapEntry) {
30
- const tableToolbar = findNestedElements(mapEntry.table, toolbars)[0];
31
- this.toolbarsMap[mapKey] = tableToolbar;
32
- const actions = tableToolbar ? await this.context.actionService.get(tableToolbar.getId()) : [];
33
- const changeToolbarContentAction = actions.find(action => action.id === ACTION_ID);
34
- child.enabled = !!changeToolbarContentAction?.enabled;
35
- let tooltip;
36
- if (!tableToolbar) {
37
- tooltip = this.context.resourceBundle.getText('TABLE_HEADER_TOOLBAR_NOT_AVAILABLE');
38
- } else if (!child.enabled) {
39
- tooltip = this.context.resourceBundle.getText('TABLE_HEADER_TOOLBAR_NOT_CHANGEABLE');
40
- }
41
- child.tooltip = tooltip ?? child.tooltip;
42
- }
43
- for (let idx = 0; idx < child.children.length; idx++) {
44
- await processChild(child.children[idx], `${mapKey}/${idx}`);
45
- }
46
- };
47
- await super.initialize();
48
-
49
- // disable nested actions based on conditions
50
- for (let idx = 0; idx < this.children.length; idx++) {
51
- await processChild(this.children[idx], `${idx}`);
52
- }
53
- }
54
- async execute(path) {
55
- const {
56
- table,
57
- sectionInfo,
58
- iconTabBarFilterKey
59
- } = this.tableMap[path];
60
- const toolbar = this.toolbarsMap[path];
61
- if (!table || !toolbar) {
62
- return [];
63
- }
64
- preprocessActionExecution(table, sectionInfo, this.iconTabBar, iconTabBarFilterKey);
65
- const toolbarControl = getControlById(toolbar.getId());
66
- const controlOverlay = OverlayUtil.getClosestOverlayFor(toolbarControl);
67
- if (controlOverlay) {
68
- controlOverlay.setSelected(true);
69
- await this.context.actionService.execute(toolbar.getId(), ACTION_ID);
70
- }
71
- return [];
72
- }
73
- }
74
- var __exports = {
75
- __esModule: true
76
- };
77
- __exports.CHANGE_TABLE_ACTIONS = CHANGE_TABLE_ACTIONS;
78
- __exports.ChangeTableActionsQuickAction = ChangeTableActionsQuickAction;
79
- return __exports;
1
+ "use strict";
2
+
3
+ sap.ui.define(["sap/ui/dt/OverlayUtil", "../../../utils/core", "../table-quick-action-base", "../control-types", "../../../cpe/quick-actions/utils", "../fe-v2/create-table-custom-column", "../dialog-enablement-validator"], function (OverlayUtil, _____utils_core, ___table_quick_action_base, ___control_types, _____cpe_quick_actions_utils, ___fe_v2_create_table_custom_column, ___dialog_enablement_validator) {
4
+ "use strict";
5
+
6
+ const getControlById = _____utils_core["getControlById"];
7
+ const findNestedElements = _____utils_core["findNestedElements"];
8
+ const TableQuickActionDefinitionBase = ___table_quick_action_base["TableQuickActionDefinitionBase"];
9
+ const MDC_ACTION_TOOLBAR_TYPE = ___control_types["MDC_ACTION_TOOLBAR_TYPE"];
10
+ const MDC_TABLE_TYPE = ___control_types["MDC_TABLE_TYPE"];
11
+ const getRelevantControlFromActivePage = _____cpe_quick_actions_utils["getRelevantControlFromActivePage"];
12
+ const preprocessActionExecution = ___fe_v2_create_table_custom_column["preprocessActionExecution"];
13
+ const DIALOG_ENABLEMENT_VALIDATOR = ___dialog_enablement_validator["DIALOG_ENABLEMENT_VALIDATOR"];
14
+ const CHANGE_TABLE_ACTIONS = 'change-table-actions';
15
+ const ACTION_ID = 'CTX_SETTINGS';
16
+
17
+ /**
18
+ * Quick Action for changing table columns.
19
+ */
20
+ class ChangeTableActionsQuickAction extends TableQuickActionDefinitionBase {
21
+ toolbarsMap = {};
22
+ constructor(context) {
23
+ super(CHANGE_TABLE_ACTIONS, [MDC_TABLE_TYPE], 'V4_QUICK_ACTION_CHANGE_TABLE_ACTIONS', context, undefined, [DIALOG_ENABLEMENT_VALIDATOR]);
24
+ }
25
+ async initialize() {
26
+ const toolbars = getRelevantControlFromActivePage(this.context.controlIndex, this.context.view, [MDC_ACTION_TOOLBAR_TYPE]);
27
+ const processChild = async (child, mapKey) => {
28
+ const mapEntry = this.tableMap[mapKey];
29
+ if (mapEntry) {
30
+ const tableToolbar = findNestedElements(mapEntry.table, toolbars)[0];
31
+ this.toolbarsMap[mapKey] = tableToolbar;
32
+ const actions = tableToolbar ? await this.context.actionService.get(tableToolbar.getId()) : [];
33
+ const changeToolbarContentAction = actions.find(action => action.id === ACTION_ID);
34
+ child.enabled = !!changeToolbarContentAction?.enabled;
35
+ let tooltip;
36
+ if (!tableToolbar) {
37
+ tooltip = this.context.resourceBundle.getText('TABLE_HEADER_TOOLBAR_NOT_AVAILABLE');
38
+ } else if (!child.enabled) {
39
+ tooltip = this.context.resourceBundle.getText('TABLE_HEADER_TOOLBAR_NOT_CHANGEABLE');
40
+ }
41
+ child.tooltip = tooltip ?? child.tooltip;
42
+ }
43
+ for (let idx = 0; idx < child.children.length; idx++) {
44
+ await processChild(child.children[idx], `${mapKey}/${idx}`);
45
+ }
46
+ };
47
+ await super.initialize();
48
+
49
+ // disable nested actions based on conditions
50
+ for (let idx = 0; idx < this.children.length; idx++) {
51
+ await processChild(this.children[idx], `${idx}`);
52
+ }
53
+ }
54
+ async execute(path) {
55
+ const {
56
+ table,
57
+ sectionInfo,
58
+ iconTabBarFilterKey
59
+ } = this.tableMap[path];
60
+ const toolbar = this.toolbarsMap[path];
61
+ if (!table || !toolbar) {
62
+ return [];
63
+ }
64
+ preprocessActionExecution(table, sectionInfo, this.iconTabBar, iconTabBarFilterKey);
65
+ const toolbarControl = getControlById(toolbar.getId());
66
+ const controlOverlay = OverlayUtil.getClosestOverlayFor(toolbarControl);
67
+ if (controlOverlay) {
68
+ controlOverlay.setSelected(true);
69
+ await this.context.actionService.execute(toolbar.getId(), ACTION_ID);
70
+ }
71
+ return [];
72
+ }
73
+ }
74
+ var __exports = {
75
+ __esModule: true
76
+ };
77
+ __exports.CHANGE_TABLE_ACTIONS = CHANGE_TABLE_ACTIONS;
78
+ __exports.ChangeTableActionsQuickAction = ChangeTableActionsQuickAction;
79
+ return __exports;
80
80
  });
81
81
  //# sourceMappingURL=change-table-actions.js.map
@@ -1,77 +1,77 @@
1
- "use strict";
2
-
3
- sap.ui.define(["sap/ui/dt/OverlayUtil", "sap/ui/fl/apply/api/FlexRuntimeInfoAPI", "../../../utils/core", "../table-quick-action-base", "../control-types", "../dialog-enablement-validator", "../../../cpe/quick-actions/utils"], function (OverlayUtil, FlexRuntimeInfoAPI, _____utils_core, ___table_quick_action_base, ___control_types, ___dialog_enablement_validator, _____cpe_quick_actions_utils) {
4
- "use strict";
5
-
6
- const getControlById = _____utils_core["getControlById"];
7
- const TableQuickActionDefinitionBase = ___table_quick_action_base["TableQuickActionDefinitionBase"];
8
- const MDC_TABLE_TYPE = ___control_types["MDC_TABLE_TYPE"];
9
- const DIALOG_ENABLEMENT_VALIDATOR = ___dialog_enablement_validator["DIALOG_ENABLEMENT_VALIDATOR"];
10
- const getRelevantControlFromActivePage = _____cpe_quick_actions_utils["getRelevantControlFromActivePage"];
11
- const CHANGE_TABLE_COLUMNS = 'change-table-columns';
12
- const ACTION_ID = 'CTX_SETTINGS0';
13
-
14
- /**
15
- * Quick Action for changing table columns.
16
- */
17
- class ChangeTableColumnsQuickAction extends TableQuickActionDefinitionBase {
18
- constructor(context) {
19
- super(CHANGE_TABLE_COLUMNS, [MDC_TABLE_TYPE], 'V4_QUICK_ACTION_CHANGE_TABLE_COLUMNS', context, undefined, [DIALOG_ENABLEMENT_VALIDATOR]);
20
- }
21
- async initialize() {
22
- for (const smartTable of getRelevantControlFromActivePage(this.context.controlIndex, this.context.view, this.controlTypes)) {
23
- const hasVariantManagement = FlexRuntimeInfoAPI.hasVariantManagement({
24
- element: smartTable
25
- });
26
- if (!hasVariantManagement) {
27
- continue;
28
- }
29
- const actions = await this.context.actionService.get(smartTable.getId());
30
- const changeColumnAction = actions.find(action => action.id === ACTION_ID);
31
- if (changeColumnAction) {
32
- const path = this.children.length.toString();
33
- this.children.push({
34
- path,
35
- label: `'${smartTable.getHeader()}' table`,
36
- enabled: true,
37
- children: []
38
- });
39
- this.tableMap[path] = {
40
- table: smartTable,
41
- tableUpdateEventAttachedOnce: false
42
- };
43
- }
44
- }
45
- if (this.children.length > 0) {
46
- this.isApplicable = true;
47
- }
48
- }
49
- async execute(path) {
50
- const {
51
- table
52
- } = this.tableMap[path];
53
- if (!table) {
54
- return [];
55
- }
56
- const tableControl = getControlById(table.getId());
57
- const controlOverlay = OverlayUtil.getClosestOverlayFor(tableControl);
58
- if (controlOverlay) {
59
- controlOverlay.setSelected(true);
60
- }
61
- const hasVariantManagement = FlexRuntimeInfoAPI.hasVariantManagement({
62
- element: table
63
- });
64
- if (hasVariantManagement) {
65
- await this.context.actionService.execute(table.getId(), ACTION_ID);
66
- }
67
- return [];
68
- }
69
- }
70
- var __exports = {
71
- __esModule: true
72
- };
73
- __exports.CHANGE_TABLE_COLUMNS = CHANGE_TABLE_COLUMNS;
74
- __exports.ChangeTableColumnsQuickAction = ChangeTableColumnsQuickAction;
75
- return __exports;
1
+ "use strict";
2
+
3
+ sap.ui.define(["sap/ui/dt/OverlayUtil", "sap/ui/fl/apply/api/FlexRuntimeInfoAPI", "../../../utils/core", "../table-quick-action-base", "../control-types", "../dialog-enablement-validator", "../../../cpe/quick-actions/utils"], function (OverlayUtil, FlexRuntimeInfoAPI, _____utils_core, ___table_quick_action_base, ___control_types, ___dialog_enablement_validator, _____cpe_quick_actions_utils) {
4
+ "use strict";
5
+
6
+ const getControlById = _____utils_core["getControlById"];
7
+ const TableQuickActionDefinitionBase = ___table_quick_action_base["TableQuickActionDefinitionBase"];
8
+ const MDC_TABLE_TYPE = ___control_types["MDC_TABLE_TYPE"];
9
+ const DIALOG_ENABLEMENT_VALIDATOR = ___dialog_enablement_validator["DIALOG_ENABLEMENT_VALIDATOR"];
10
+ const getRelevantControlFromActivePage = _____cpe_quick_actions_utils["getRelevantControlFromActivePage"];
11
+ const CHANGE_TABLE_COLUMNS = 'change-table-columns';
12
+ const ACTION_ID = 'CTX_SETTINGS0';
13
+
14
+ /**
15
+ * Quick Action for changing table columns.
16
+ */
17
+ class ChangeTableColumnsQuickAction extends TableQuickActionDefinitionBase {
18
+ constructor(context) {
19
+ super(CHANGE_TABLE_COLUMNS, [MDC_TABLE_TYPE], 'V4_QUICK_ACTION_CHANGE_TABLE_COLUMNS', context, undefined, [DIALOG_ENABLEMENT_VALIDATOR]);
20
+ }
21
+ async initialize() {
22
+ for (const smartTable of getRelevantControlFromActivePage(this.context.controlIndex, this.context.view, this.controlTypes)) {
23
+ const hasVariantManagement = FlexRuntimeInfoAPI.hasVariantManagement({
24
+ element: smartTable
25
+ });
26
+ if (!hasVariantManagement) {
27
+ continue;
28
+ }
29
+ const actions = await this.context.actionService.get(smartTable.getId());
30
+ const changeColumnAction = actions.find(action => action.id === ACTION_ID);
31
+ if (changeColumnAction) {
32
+ const path = this.children.length.toString();
33
+ this.children.push({
34
+ path,
35
+ label: `'${smartTable.getHeader()}' table`,
36
+ enabled: true,
37
+ children: []
38
+ });
39
+ this.tableMap[path] = {
40
+ table: smartTable,
41
+ tableUpdateEventAttachedOnce: false
42
+ };
43
+ }
44
+ }
45
+ if (this.children.length > 0) {
46
+ this.isApplicable = true;
47
+ }
48
+ }
49
+ async execute(path) {
50
+ const {
51
+ table
52
+ } = this.tableMap[path];
53
+ if (!table) {
54
+ return [];
55
+ }
56
+ const tableControl = getControlById(table.getId());
57
+ const controlOverlay = OverlayUtil.getClosestOverlayFor(tableControl);
58
+ if (controlOverlay) {
59
+ controlOverlay.setSelected(true);
60
+ }
61
+ const hasVariantManagement = FlexRuntimeInfoAPI.hasVariantManagement({
62
+ element: table
63
+ });
64
+ if (hasVariantManagement) {
65
+ await this.context.actionService.execute(table.getId(), ACTION_ID);
66
+ }
67
+ return [];
68
+ }
69
+ }
70
+ var __exports = {
71
+ __esModule: true
72
+ };
73
+ __exports.CHANGE_TABLE_COLUMNS = CHANGE_TABLE_COLUMNS;
74
+ __exports.ChangeTableColumnsQuickAction = ChangeTableColumnsQuickAction;
75
+ return __exports;
76
76
  });
77
77
  //# sourceMappingURL=change-table-columns.js.map
@@ -1,55 +1,55 @@
1
- "use strict";
2
-
3
- sap.ui.define(["sap/ui/dt/OverlayUtil", "../../../utils/core", "../../dialog-factory", "../dialog-enablement-validator", "../table-quick-action-base", "../control-types", "../fe-v2/create-table-custom-column"], function (OverlayUtil, _____utils_core, ____dialog_factory, ___dialog_enablement_validator, ___table_quick_action_base, ___control_types, ___fe_v2_create_table_custom_column) {
4
- "use strict";
5
-
6
- const getControlById = _____utils_core["getControlById"];
7
- const DialogFactory = ____dialog_factory["DialogFactory"];
8
- const DialogNames = ____dialog_factory["DialogNames"];
9
- const DIALOG_ENABLEMENT_VALIDATOR = ___dialog_enablement_validator["DIALOG_ENABLEMENT_VALIDATOR"];
10
- const TableQuickActionDefinitionBase = ___table_quick_action_base["TableQuickActionDefinitionBase"];
11
- const MDC_TABLE_TYPE = ___control_types["MDC_TABLE_TYPE"];
12
- const preprocessActionExecution = ___fe_v2_create_table_custom_column["preprocessActionExecution"];
13
- const CREATE_TABLE_ACTION = 'create_table_action';
14
-
15
- /**
16
- * Quick Action for creating table action.
17
- */
18
- class AddTableActionQuickAction extends TableQuickActionDefinitionBase {
19
- constructor(context) {
20
- super(CREATE_TABLE_ACTION, [MDC_TABLE_TYPE], 'QUICK_ACTION_ADD_CUSTOM_TABLE_ACTION', context, undefined, [DIALOG_ENABLEMENT_VALIDATOR]);
21
- }
22
- async execute(path) {
23
- const {
24
- table,
25
- sectionInfo,
26
- iconTabBarFilterKey
27
- } = this.tableMap[path];
28
- if (!table) {
29
- return [];
30
- }
31
- preprocessActionExecution(table, sectionInfo, this.iconTabBar, iconTabBarFilterKey);
32
- const tableControl = getControlById(table.getId());
33
- const controlOverlay = OverlayUtil.getClosestOverlayFor(tableControl);
34
- if (controlOverlay) {
35
- controlOverlay.setSelected(true);
36
- await DialogFactory.createDialog(controlOverlay, this.context.rta, DialogNames.ADD_FRAGMENT, undefined, {
37
- aggregation: 'actions',
38
- defaultAggregationArrayIndex: 0,
39
- title: 'QUICK_ACTION_ADD_CUSTOM_TABLE_ACTION'
40
- }, {
41
- actionName: this.type,
42
- telemetryEventIdentifier: this.getTelemetryIdentifier()
43
- });
44
- }
45
- return [];
46
- }
47
- }
48
- var __exports = {
49
- __esModule: true
50
- };
51
- __exports.CREATE_TABLE_ACTION = CREATE_TABLE_ACTION;
52
- __exports.AddTableActionQuickAction = AddTableActionQuickAction;
53
- return __exports;
1
+ "use strict";
2
+
3
+ sap.ui.define(["sap/ui/dt/OverlayUtil", "../../../utils/core", "../../dialog-factory", "../dialog-enablement-validator", "../table-quick-action-base", "../control-types", "../fe-v2/create-table-custom-column"], function (OverlayUtil, _____utils_core, ____dialog_factory, ___dialog_enablement_validator, ___table_quick_action_base, ___control_types, ___fe_v2_create_table_custom_column) {
4
+ "use strict";
5
+
6
+ const getControlById = _____utils_core["getControlById"];
7
+ const DialogFactory = ____dialog_factory["DialogFactory"];
8
+ const DialogNames = ____dialog_factory["DialogNames"];
9
+ const DIALOG_ENABLEMENT_VALIDATOR = ___dialog_enablement_validator["DIALOG_ENABLEMENT_VALIDATOR"];
10
+ const TableQuickActionDefinitionBase = ___table_quick_action_base["TableQuickActionDefinitionBase"];
11
+ const MDC_TABLE_TYPE = ___control_types["MDC_TABLE_TYPE"];
12
+ const preprocessActionExecution = ___fe_v2_create_table_custom_column["preprocessActionExecution"];
13
+ const CREATE_TABLE_ACTION = 'create_table_action';
14
+
15
+ /**
16
+ * Quick Action for creating table action.
17
+ */
18
+ class AddTableActionQuickAction extends TableQuickActionDefinitionBase {
19
+ constructor(context) {
20
+ super(CREATE_TABLE_ACTION, [MDC_TABLE_TYPE], 'QUICK_ACTION_ADD_CUSTOM_TABLE_ACTION', context, undefined, [DIALOG_ENABLEMENT_VALIDATOR]);
21
+ }
22
+ async execute(path) {
23
+ const {
24
+ table,
25
+ sectionInfo,
26
+ iconTabBarFilterKey
27
+ } = this.tableMap[path];
28
+ if (!table) {
29
+ return [];
30
+ }
31
+ preprocessActionExecution(table, sectionInfo, this.iconTabBar, iconTabBarFilterKey);
32
+ const tableControl = getControlById(table.getId());
33
+ const controlOverlay = OverlayUtil.getClosestOverlayFor(tableControl);
34
+ if (controlOverlay) {
35
+ controlOverlay.setSelected(true);
36
+ await DialogFactory.createDialog(controlOverlay, this.context.rta, DialogNames.ADD_FRAGMENT, undefined, {
37
+ aggregation: 'actions',
38
+ defaultAggregationArrayIndex: 0,
39
+ title: 'QUICK_ACTION_ADD_CUSTOM_TABLE_ACTION'
40
+ }, {
41
+ actionName: this.type,
42
+ telemetryEventIdentifier: this.getTelemetryIdentifier()
43
+ });
44
+ }
45
+ return [];
46
+ }
47
+ }
48
+ var __exports = {
49
+ __esModule: true
50
+ };
51
+ __exports.CREATE_TABLE_ACTION = CREATE_TABLE_ACTION;
52
+ __exports.AddTableActionQuickAction = AddTableActionQuickAction;
53
+ return __exports;
54
54
  });
55
55
  //# sourceMappingURL=create-table-action.js.map
@@ -1,51 +1,51 @@
1
- "use strict";
2
-
3
- sap.ui.define(["sap/ui/dt/OverlayRegistry", "../../dialog-factory", "../control-types", "../table-quick-action-base", "../fe-v2/create-table-custom-column", "../dialog-enablement-validator"], function (OverlayRegistry, ____dialog_factory, ___control_types, ___table_quick_action_base, ___fe_v2_create_table_custom_column, ___dialog_enablement_validator) {
4
- "use strict";
5
-
6
- const DialogFactory = ____dialog_factory["DialogFactory"];
7
- const DialogNames = ____dialog_factory["DialogNames"];
8
- const SMART_TABLE_TYPE = ___control_types["SMART_TABLE_TYPE"];
9
- const GRID_TABLE_TYPE = ___control_types["GRID_TABLE_TYPE"];
10
- const MDC_TABLE_TYPE = ___control_types["MDC_TABLE_TYPE"];
11
- const TREE_TABLE_TYPE = ___control_types["TREE_TABLE_TYPE"];
12
- const TableQuickActionDefinitionBase = ___table_quick_action_base["TableQuickActionDefinitionBase"];
13
- const preprocessActionExecution = ___fe_v2_create_table_custom_column["preprocessActionExecution"];
14
- const DIALOG_ENABLEMENT_VALIDATOR = ___dialog_enablement_validator["DIALOG_ENABLEMENT_VALIDATOR"];
15
- const CREATE_TABLE_CUSTOM_COLUMN = 'create-table-custom-column';
16
- const CONTROL_TYPES = [SMART_TABLE_TYPE, MDC_TABLE_TYPE, TREE_TABLE_TYPE, GRID_TABLE_TYPE];
17
- class AddTableCustomColumnQuickAction extends TableQuickActionDefinitionBase {
18
- constructor(context) {
19
- super(CREATE_TABLE_CUSTOM_COLUMN, CONTROL_TYPES, 'QUICK_ACTION_ADD_CUSTOM_TABLE_COLUMN', context, undefined, [DIALOG_ENABLEMENT_VALIDATOR]);
20
- }
21
- async execute(path) {
22
- const {
23
- table,
24
- iconTabBarFilterKey,
25
- sectionInfo
26
- } = this.tableMap[path];
27
- if (!table) {
28
- return [];
29
- }
30
- preprocessActionExecution(table, sectionInfo, this.iconTabBar, iconTabBarFilterKey);
31
- this.selectOverlay(table);
32
- const overlay = OverlayRegistry.getOverlay(table);
33
- await DialogFactory.createDialog(overlay, this.context.rta, DialogNames.ADD_FRAGMENT, undefined, {
34
- aggregation: 'columns',
35
- title: 'QUICK_ACTION_ADD_CUSTOM_TABLE_COLUMN'
36
- }, {
37
- actionName: this.type,
38
- telemetryEventIdentifier: this.getTelemetryIdentifier()
39
- });
40
- return [];
41
- }
42
- }
43
- var __exports = {
44
- __esModule: true
45
- };
46
- __exports.CREATE_TABLE_CUSTOM_COLUMN = CREATE_TABLE_CUSTOM_COLUMN;
47
- __exports.CONTROL_TYPES = CONTROL_TYPES;
48
- __exports.AddTableCustomColumnQuickAction = AddTableCustomColumnQuickAction;
49
- return __exports;
1
+ "use strict";
2
+
3
+ sap.ui.define(["sap/ui/dt/OverlayRegistry", "../../dialog-factory", "../control-types", "../table-quick-action-base", "../fe-v2/create-table-custom-column", "../dialog-enablement-validator"], function (OverlayRegistry, ____dialog_factory, ___control_types, ___table_quick_action_base, ___fe_v2_create_table_custom_column, ___dialog_enablement_validator) {
4
+ "use strict";
5
+
6
+ const DialogFactory = ____dialog_factory["DialogFactory"];
7
+ const DialogNames = ____dialog_factory["DialogNames"];
8
+ const SMART_TABLE_TYPE = ___control_types["SMART_TABLE_TYPE"];
9
+ const GRID_TABLE_TYPE = ___control_types["GRID_TABLE_TYPE"];
10
+ const MDC_TABLE_TYPE = ___control_types["MDC_TABLE_TYPE"];
11
+ const TREE_TABLE_TYPE = ___control_types["TREE_TABLE_TYPE"];
12
+ const TableQuickActionDefinitionBase = ___table_quick_action_base["TableQuickActionDefinitionBase"];
13
+ const preprocessActionExecution = ___fe_v2_create_table_custom_column["preprocessActionExecution"];
14
+ const DIALOG_ENABLEMENT_VALIDATOR = ___dialog_enablement_validator["DIALOG_ENABLEMENT_VALIDATOR"];
15
+ const CREATE_TABLE_CUSTOM_COLUMN = 'create-table-custom-column';
16
+ const CONTROL_TYPES = [SMART_TABLE_TYPE, MDC_TABLE_TYPE, TREE_TABLE_TYPE, GRID_TABLE_TYPE];
17
+ class AddTableCustomColumnQuickAction extends TableQuickActionDefinitionBase {
18
+ constructor(context) {
19
+ super(CREATE_TABLE_CUSTOM_COLUMN, CONTROL_TYPES, 'QUICK_ACTION_ADD_CUSTOM_TABLE_COLUMN', context, undefined, [DIALOG_ENABLEMENT_VALIDATOR]);
20
+ }
21
+ async execute(path) {
22
+ const {
23
+ table,
24
+ iconTabBarFilterKey,
25
+ sectionInfo
26
+ } = this.tableMap[path];
27
+ if (!table) {
28
+ return [];
29
+ }
30
+ preprocessActionExecution(table, sectionInfo, this.iconTabBar, iconTabBarFilterKey);
31
+ this.selectOverlay(table);
32
+ const overlay = OverlayRegistry.getOverlay(table);
33
+ await DialogFactory.createDialog(overlay, this.context.rta, DialogNames.ADD_FRAGMENT, undefined, {
34
+ aggregation: 'columns',
35
+ title: 'QUICK_ACTION_ADD_CUSTOM_TABLE_COLUMN'
36
+ }, {
37
+ actionName: this.type,
38
+ telemetryEventIdentifier: this.getTelemetryIdentifier()
39
+ });
40
+ return [];
41
+ }
42
+ }
43
+ var __exports = {
44
+ __esModule: true
45
+ };
46
+ __exports.CREATE_TABLE_CUSTOM_COLUMN = CREATE_TABLE_CUSTOM_COLUMN;
47
+ __exports.CONTROL_TYPES = CONTROL_TYPES;
48
+ __exports.AddTableCustomColumnQuickAction = AddTableCustomColumnQuickAction;
49
+ return __exports;
50
50
  });
51
51
  //# sourceMappingURL=create-table-custom-column.js.map