@sap/ux-specification 1.96.25 → 1.96.27
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/dist/documentation/v2/v2-AnalyticalListPage.html +1 -1
- package/dist/documentation/v2/v2-ApplicationV2.html +1 -1
- package/dist/documentation/v2/v2-ListReport.html +1 -1
- package/dist/documentation/v2/v2-ObjectPage.html +1 -1
- package/dist/documentation/v2/v2-OverviewPage.html +1 -1
- package/dist/documentation/v4/v4-ApplicationV4.html +1 -1
- package/dist/documentation/v4/v4-FreestylePage.html +1 -1
- package/dist/documentation/v4/v4-ListReport.html +1 -1
- package/dist/documentation/v4/v4-ObjectPage.html +1 -1
- package/dist/index-min.js +185 -55
- package/dist/index-min.js.map +3 -3
- package/dist/schemas/v2/AnalyticalListPageConfig.json +9 -0
- package/dist/schemas/v2/ListReportConfig.json +9 -0
- package/dist/schemas/v2/ObjectPageConfig.json +13 -4
- package/dist/schemas/v4/ListReportConfig.json +66 -43
- package/dist/schemas/v4/ObjectPageConfig.json +209 -59
- package/dist/scripts/to-json-schema.d.ts.map +1 -1
- package/dist/scripts/to-json-schema.js +9 -1
- package/dist/scripts/to-json-schema.js.map +1 -1
- package/dist/src/api.d.ts +1 -2
- package/dist/src/api.d.ts.map +1 -1
- package/dist/src/api.js +14 -6
- package/dist/src/api.js.map +1 -1
- package/dist/src/extensionLogger.d.ts +1 -24
- package/dist/src/extensionLogger.d.ts.map +1 -1
- package/dist/src/extensionLogger.js +5 -15
- package/dist/src/extensionLogger.js.map +1 -1
- package/dist/src/index.d.ts +0 -2
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +0 -2
- package/dist/src/index.js.map +1 -1
- package/dist/src/project.d.ts +1 -2
- package/dist/src/project.d.ts.map +1 -1
- package/dist/src/project.js.map +1 -1
- package/dist/src/sync/common/appProvider.d.ts +1 -3
- package/dist/src/sync/common/appProvider.d.ts.map +1 -1
- package/dist/src/sync/common/appProvider.js +3 -4
- package/dist/src/sync/common/appProvider.js.map +1 -1
- package/dist/src/sync/common/decoration/control.d.ts +1 -1
- package/dist/src/sync/common/decoration/control.d.ts.map +1 -1
- package/dist/src/sync/common/decoration/control.js +12 -12
- package/dist/src/sync/common/decoration/control.js.map +1 -1
- package/dist/src/sync/common/decoration/decorators.d.ts +1 -1
- package/dist/src/sync/common/decoration/decorators.d.ts.map +1 -1
- package/dist/src/sync/common/decoration/flex.d.ts +1 -2
- package/dist/src/sync/common/decoration/flex.d.ts.map +1 -1
- package/dist/src/sync/common/decoration/flex.js.map +1 -1
- package/dist/src/sync/common/flexUtils.d.ts +1 -4
- package/dist/src/sync/common/flexUtils.d.ts.map +1 -1
- package/dist/src/sync/common/flexUtils.js.map +1 -1
- package/dist/src/sync/common/generate/objectPage.d.ts +12 -8
- package/dist/src/sync/common/generate/objectPage.d.ts.map +1 -1
- package/dist/src/sync/common/generate/objectPage.js +226 -115
- package/dist/src/sync/common/generate/objectPage.js.map +1 -1
- package/dist/src/sync/common/generate/utils.d.ts +20 -4
- package/dist/src/sync/common/generate/utils.d.ts.map +1 -1
- package/dist/src/sync/common/generate/utils.js +93 -27
- package/dist/src/sync/common/generate/utils.js.map +1 -1
- package/dist/src/sync/common/import/utils.d.ts +1 -2
- package/dist/src/sync/common/import/utils.d.ts.map +1 -1
- package/dist/src/sync/common/import/utils.js +4 -3
- package/dist/src/sync/common/import/utils.js.map +1 -1
- package/dist/src/sync/common/importProject.d.ts +1 -2
- package/dist/src/sync/common/importProject.d.ts.map +1 -1
- package/dist/src/sync/common/importProject.js +22 -23
- package/dist/src/sync/common/importProject.js.map +1 -1
- package/dist/src/sync/common/index.d.ts +0 -1
- package/dist/src/sync/common/index.d.ts.map +1 -1
- package/dist/src/sync/common/index.js +0 -1
- package/dist/src/sync/common/index.js.map +1 -1
- package/dist/src/sync/common/utils.d.ts +2 -12
- package/dist/src/sync/common/utils.d.ts.map +1 -1
- package/dist/src/sync/common/utils.js +67 -61
- package/dist/src/sync/common/utils.js.map +1 -1
- package/dist/src/sync/v2/application.d.ts.map +1 -1
- package/dist/src/sync/v2/application.js +1 -2
- package/dist/src/sync/v2/application.js.map +1 -1
- package/dist/src/sync/v2/export/controls/AnalyticalListPageChart.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/AnalyticalListPageChart.js +1 -2
- package/dist/src/sync/v2/export/controls/AnalyticalListPageChart.js.map +1 -1
- package/dist/src/sync/v2/export/controls/Field.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/Field.js.map +1 -1
- package/dist/src/sync/v2/export/controls/FilterBar.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/FilterBar.js +4 -5
- package/dist/src/sync/v2/export/controls/FilterBar.js.map +1 -1
- package/dist/src/sync/v2/export/controls/FormAction.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/FormAction.js.map +1 -1
- package/dist/src/sync/v2/export/controls/Fragment.d.ts +2 -4
- package/dist/src/sync/v2/export/controls/Fragment.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/Fragment.js +12 -13
- package/dist/src/sync/v2/export/controls/Fragment.js.map +1 -1
- package/dist/src/sync/v2/export/controls/ObjectPageFooterAction.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/ObjectPageFooterAction.js.map +1 -1
- package/dist/src/sync/v2/export/controls/ObjectPageHeader.d.ts +2 -2
- package/dist/src/sync/v2/export/controls/ObjectPageHeader.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/ObjectPageHeaderAction.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/ObjectPageHeaderAction.js.map +1 -1
- package/dist/src/sync/v2/export/controls/ObjectPageSectionsV2.d.ts +1 -3
- package/dist/src/sync/v2/export/controls/ObjectPageSectionsV2.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/ObjectPageSectionsV2.js +2 -3
- package/dist/src/sync/v2/export/controls/ObjectPageSectionsV2.js.map +1 -1
- package/dist/src/sync/v2/export/controls/ObjectPageTable.d.ts +1 -2
- package/dist/src/sync/v2/export/controls/ObjectPageTable.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/ObjectPageTable.js +3 -3
- package/dist/src/sync/v2/export/controls/ObjectPageTable.js.map +1 -1
- package/dist/src/sync/v2/export/controls/Table.d.ts +1 -2
- package/dist/src/sync/v2/export/controls/Table.d.ts.map +1 -1
- package/dist/src/sync/v2/export/controls/Table.js +6 -6
- package/dist/src/sync/v2/export/controls/Table.js.map +1 -1
- package/dist/src/sync/v2/export/controls/TableColumn.d.ts +1 -1
- package/dist/src/sync/v2/export/controls/TableColumn.js +1 -1
- package/dist/src/sync/v2/export/export.d.ts +1 -1
- package/dist/src/sync/v2/export/export.d.ts.map +1 -1
- package/dist/src/sync/v2/export/export.js +6 -6
- package/dist/src/sync/v2/export/export.js.map +1 -1
- package/dist/src/sync/v2/export/exportPage.d.ts +1 -2
- package/dist/src/sync/v2/export/exportPage.d.ts.map +1 -1
- package/dist/src/sync/v2/export/exportPage.js +1 -1
- package/dist/src/sync/v2/export/exportPage.js.map +1 -1
- package/dist/src/sync/v2/export/view-controller-generator.d.ts +1 -2
- package/dist/src/sync/v2/export/view-controller-generator.d.ts.map +1 -1
- package/dist/src/sync/v2/export/view-controller-generator.js +2 -2
- package/dist/src/sync/v2/export/view-controller-generator.js.map +1 -1
- package/dist/src/sync/v2/generate/analyticalListReport.d.ts +1 -1
- package/dist/src/sync/v2/generate/analyticalListReport.d.ts.map +1 -1
- package/dist/src/sync/v2/generate/analyticalListReport.js +10 -10
- package/dist/src/sync/v2/generate/analyticalListReport.js.map +1 -1
- package/dist/src/sync/v2/generate/generate.d.ts +1 -2
- package/dist/src/sync/v2/generate/generate.d.ts.map +1 -1
- package/dist/src/sync/v2/generate/generate.js +3 -3
- package/dist/src/sync/v2/generate/generate.js.map +1 -1
- package/dist/src/sync/v2/generate/listReport.d.ts +1 -1
- package/dist/src/sync/v2/generate/listReport.d.ts.map +1 -1
- package/dist/src/sync/v2/generate/listReport.js +5 -5
- package/dist/src/sync/v2/generate/listReport.js.map +1 -1
- package/dist/src/sync/v2/generate/objectPage.d.ts +1 -1
- package/dist/src/sync/v2/generate/objectPage.d.ts.map +1 -1
- package/dist/src/sync/v2/generate/objectPage.js +114 -78
- package/dist/src/sync/v2/generate/objectPage.js.map +1 -1
- package/dist/src/sync/v2/generate/utils.d.ts +3 -4
- package/dist/src/sync/v2/generate/utils.d.ts.map +1 -1
- package/dist/src/sync/v2/generate/utils.js +53 -40
- package/dist/src/sync/v2/generate/utils.js.map +1 -1
- package/dist/src/sync/v2/import/app/appProvider.d.ts +1 -3
- package/dist/src/sync/v2/import/app/appProvider.d.ts.map +1 -1
- package/dist/src/sync/v2/import/app/appProvider.js.map +1 -1
- package/dist/src/sync/v2/import/app/ovpProvider.d.ts +1 -2
- package/dist/src/sync/v2/import/app/ovpProvider.d.ts.map +1 -1
- package/dist/src/sync/v2/import/app/ovpProvider.js.map +1 -1
- package/dist/src/sync/v2/import/common/index.d.ts +1 -3
- package/dist/src/sync/v2/import/common/index.d.ts.map +1 -1
- package/dist/src/sync/v2/import/common/index.js +9 -9
- package/dist/src/sync/v2/import/common/index.js.map +1 -1
- package/dist/src/sync/v2/import/controls/table.d.ts.map +1 -1
- package/dist/src/sync/v2/import/controls/table.js +3 -4
- package/dist/src/sync/v2/import/controls/table.js.map +1 -1
- package/dist/src/sync/v2/import/pages/analyticalListPage.d.ts +1 -2
- package/dist/src/sync/v2/import/pages/analyticalListPage.d.ts.map +1 -1
- package/dist/src/sync/v2/import/pages/analyticalListPage.js +16 -16
- package/dist/src/sync/v2/import/pages/analyticalListPage.js.map +1 -1
- package/dist/src/sync/v2/import/pages/listReport.d.ts +1 -2
- package/dist/src/sync/v2/import/pages/listReport.d.ts.map +1 -1
- package/dist/src/sync/v2/import/pages/listReport.js +15 -15
- package/dist/src/sync/v2/import/pages/listReport.js.map +1 -1
- package/dist/src/sync/v2/import/pages/objectPage.d.ts +1 -1
- package/dist/src/sync/v2/import/pages/objectPage.d.ts.map +1 -1
- package/dist/src/sync/v2/import/pages/objectPage.js +31 -31
- package/dist/src/sync/v2/import/pages/objectPage.js.map +1 -1
- package/dist/src/sync/v2/import/utils.d.ts.map +1 -1
- package/dist/src/sync/v2/import/utils.js +1 -1
- package/dist/src/sync/v2/import/utils.js.map +1 -1
- package/dist/src/sync/v4/application.d.ts +3 -0
- package/dist/src/sync/v4/application.d.ts.map +1 -1
- package/dist/src/sync/v4/application.js +15 -3
- package/dist/src/sync/v4/application.js.map +1 -1
- package/dist/src/sync/v4/export/controls/ObjectPageFooter.d.ts +5 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFooter.d.ts.map +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFooter.js +7 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFooter.js.map +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFooterAction.d.ts +9 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFooterAction.d.ts.map +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFooterAction.js +42 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFooterAction.js.map +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageForm.d.ts +16 -0
- package/dist/src/sync/v4/export/controls/ObjectPageForm.d.ts.map +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageForm.js +48 -0
- package/dist/src/sync/v4/export/controls/ObjectPageForm.js.map +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFormAction.d.ts +10 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFormAction.d.ts.map +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFormAction.js +68 -0
- package/dist/src/sync/v4/export/controls/ObjectPageFormAction.js.map +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageHeader.d.ts +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageHeader.d.ts.map +1 -1
- package/dist/src/sync/v4/export/controls/ObjectPageHeader.js.map +1 -1
- package/dist/src/sync/v4/export/controls/ObjectPageHeaderAction.d.ts +9 -0
- package/dist/src/sync/v4/export/controls/ObjectPageHeaderAction.d.ts.map +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageHeaderAction.js +42 -0
- package/dist/src/sync/v4/export/controls/ObjectPageHeaderAction.js.map +1 -0
- package/dist/src/sync/v4/export/controls/ObjectPageTable.js +4 -4
- package/dist/src/sync/v4/export/controls/ObjectPageTable.js.map +1 -1
- package/dist/src/sync/v4/export/controls/ObjectPageTableColumn.d.ts +1 -2
- package/dist/src/sync/v4/export/controls/ObjectPageTableColumn.d.ts.map +1 -1
- package/dist/src/sync/v4/export/controls/ObjectPageTableColumn.js +0 -10
- package/dist/src/sync/v4/export/controls/ObjectPageTableColumn.js.map +1 -1
- package/dist/src/sync/v4/export/controls/ObjectPageToolBarAction.d.ts +1 -1
- package/dist/src/sync/v4/export/controls/ObjectPageToolBarAction.d.ts.map +1 -1
- package/dist/src/sync/v4/export/controls/ObjectPageToolBarAction.js +9 -9
- package/dist/src/sync/v4/export/controls/ObjectPageToolBarAction.js.map +1 -1
- package/dist/src/sync/v4/export/controls/Table.d.ts.map +1 -1
- package/dist/src/sync/v4/export/controls/Table.js +2 -1
- package/dist/src/sync/v4/export/controls/Table.js.map +1 -1
- package/dist/src/sync/v4/export/controls/ToolBar.d.ts +2 -2
- package/dist/src/sync/v4/export/controls/ToolBar.d.ts.map +1 -1
- package/dist/src/sync/v4/export/controls/ToolBarAction.d.ts +6 -1
- package/dist/src/sync/v4/export/controls/ToolBarAction.d.ts.map +1 -1
- package/dist/src/sync/v4/export/controls/ToolBarAction.js +33 -9
- package/dist/src/sync/v4/export/controls/ToolBarAction.js.map +1 -1
- package/dist/src/sync/v4/export/controls/index.d.ts +6 -0
- package/dist/src/sync/v4/export/controls/index.d.ts.map +1 -1
- package/dist/src/sync/v4/export/controls/index.js +6 -0
- package/dist/src/sync/v4/export/controls/index.js.map +1 -1
- package/dist/src/sync/v4/export/export.d.ts +1 -3
- package/dist/src/sync/v4/export/export.d.ts.map +1 -1
- package/dist/src/sync/v4/export/export.js +36 -36
- package/dist/src/sync/v4/export/export.js.map +1 -1
- package/dist/src/sync/v4/export/exportCustomColumn.d.ts +1 -1
- package/dist/src/sync/v4/export/exportCustomColumn.d.ts.map +1 -1
- package/dist/src/sync/v4/export/exportCustomColumn.js +3 -4
- package/dist/src/sync/v4/export/exportCustomColumn.js.map +1 -1
- package/dist/src/sync/v4/export/manifest.js +1 -1
- package/dist/src/sync/v4/export/manifest.js.map +1 -1
- package/dist/src/sync/v4/export/pages/ObjectPage.d.ts +1 -0
- package/dist/src/sync/v4/export/pages/ObjectPage.d.ts.map +1 -1
- package/dist/src/sync/v4/export/pages/ObjectPage.js.map +1 -1
- package/dist/src/sync/v4/export/types.d.ts +1 -3
- package/dist/src/sync/v4/export/types.d.ts.map +1 -1
- package/dist/src/sync/v4/generate/freestylePage.d.ts +1 -1
- package/dist/src/sync/v4/generate/freestylePage.d.ts.map +1 -1
- package/dist/src/sync/v4/generate/generate.d.ts +2 -3
- package/dist/src/sync/v4/generate/generate.d.ts.map +1 -1
- package/dist/src/sync/v4/generate/generate.js +2 -2
- package/dist/src/sync/v4/generate/generate.js.map +1 -1
- package/dist/src/sync/v4/generate/listReport.d.ts +1 -1
- package/dist/src/sync/v4/generate/listReport.d.ts.map +1 -1
- package/dist/src/sync/v4/generate/listReport.js +137 -120
- package/dist/src/sync/v4/generate/listReport.js.map +1 -1
- package/dist/src/sync/v4/generate/objectPage.d.ts.map +1 -1
- package/dist/src/sync/v4/generate/objectPage.js +245 -159
- package/dist/src/sync/v4/generate/objectPage.js.map +1 -1
- package/dist/src/sync/v4/import/app/appProvider.d.ts +1 -2
- package/dist/src/sync/v4/import/app/appProvider.d.ts.map +1 -1
- package/dist/src/sync/v4/import/app/appProvider.js.map +1 -1
- package/dist/src/sync/v4/import/app/baseAppProvider.d.ts +2 -4
- package/dist/src/sync/v4/import/app/baseAppProvider.d.ts.map +1 -1
- package/dist/src/sync/v4/import/app/baseAppProvider.js +4 -4
- package/dist/src/sync/v4/import/app/baseAppProvider.js.map +1 -1
- package/dist/src/sync/v4/import/app/freestyleProvider.d.ts +1 -2
- package/dist/src/sync/v4/import/app/freestyleProvider.d.ts.map +1 -1
- package/dist/src/sync/v4/import/app/freestyleProvider.js.map +1 -1
- package/dist/src/sync/v4/import/fragment.d.ts +1 -2
- package/dist/src/sync/v4/import/fragment.d.ts.map +1 -1
- package/dist/src/sync/v4/import/fragment.js.map +1 -1
- package/dist/src/sync/v4/import/pages/listReport.d.ts +1 -2
- package/dist/src/sync/v4/import/pages/listReport.d.ts.map +1 -1
- package/dist/src/sync/v4/import/pages/listReport.js +36 -36
- package/dist/src/sync/v4/import/pages/listReport.js.map +1 -1
- package/dist/src/sync/v4/import/pages/objectPage.d.ts +3 -3
- package/dist/src/sync/v4/import/pages/objectPage.d.ts.map +1 -1
- package/dist/src/sync/v4/import/pages/objectPage.js +125 -28
- package/dist/src/sync/v4/import/pages/objectPage.js.map +1 -1
- package/dist/src/sync/v4/utils/StableIdHelper.d.ts +4 -0
- package/dist/src/sync/v4/utils/StableIdHelper.d.ts.map +1 -1
- package/dist/src/sync/v4/utils/StableIdHelper.js +3 -11
- package/dist/src/sync/v4/utils/StableIdHelper.js.map +1 -1
- package/dist/src/sync/v4/utils/utils.d.ts +5 -6
- package/dist/src/sync/v4/utils/utils.d.ts.map +1 -1
- package/dist/src/sync/v4/utils/utils.js +109 -68
- package/dist/src/sync/v4/utils/utils.js.map +1 -1
- package/package.json +4 -19
- package/dist/src/apiTypes.d.ts +0 -335
- package/dist/src/apiTypes.d.ts.map +0 -1
- package/dist/src/apiTypes.js +0 -25
- package/dist/src/apiTypes.js.map +0 -1
- package/dist/src/sync/common/types.d.ts +0 -306
- package/dist/src/sync/common/types.d.ts.map +0 -1
- package/dist/src/sync/common/types.js +0 -176
- package/dist/src/sync/common/types.js.map +0 -1
|
@@ -9,6 +9,7 @@ const extensionLogger_1 = require("../../../extensionLogger");
|
|
|
9
9
|
const ux_specification_types_1 = require("@sap/ux-specification-types");
|
|
10
10
|
const common_1 = require("../../common");
|
|
11
11
|
const utils_1 = require("../utils/utils");
|
|
12
|
+
const StableIdHelper_1 = require("../../v4/utils/StableIdHelper");
|
|
12
13
|
/**
|
|
13
14
|
* Callback for adding a single action to headerActions of V4
|
|
14
15
|
* @param {EntityType} entityType - current entity type
|
|
@@ -21,18 +22,52 @@ function addHeaderActionCallBackV4(entityType, appSchema, actionAnnotation, head
|
|
|
21
22
|
return (item, index) => {
|
|
22
23
|
if ((!item['Determining'] && item.$Type === "com.sap.vocabularies.UI.v1.DataFieldForAction" /* DataFieldForAction */) ||
|
|
23
24
|
item.$Type === "com.sap.vocabularies.UI.v1.DataFieldForIntentBasedNavigation" /* DataFieldForIntentBasedNavigation */) {
|
|
24
|
-
const
|
|
25
|
-
|
|
25
|
+
const { actionName, actionId, namespace } = common_1.getActionNameAndId(item, entityType, oDataServiceAVT);
|
|
26
|
+
if (!actionId) {
|
|
27
|
+
return;
|
|
28
|
+
}
|
|
29
|
+
const stableId = StableIdHelper_1.getStableIdPartFromDataField(item);
|
|
30
|
+
//stableId is used as key in V4, as the DataFieldForAction:: prefix shall be present in manifest settings
|
|
26
31
|
const convertedIdentification = actionAnnotation.fullyQualifiedName.replace(`@${"com.sap.vocabularies.UI.v1.Identification" /* Identification */}`, `/@${"com.sap.vocabularies.UI.v1.Identification" /* Identification */}`);
|
|
27
|
-
const actionDefinitionKey = `HeaderAction<${common_1.prepareRef(
|
|
32
|
+
const actionDefinitionKey = `HeaderAction<${common_1.prepareRef(stableId)}>`;
|
|
28
33
|
const headerAction = (appSchema.definitions[actionDefinitionKey] = {
|
|
29
34
|
type: 'object',
|
|
30
|
-
|
|
31
|
-
description: item
|
|
35
|
+
$ref: `${common_1.DEFINITION_LINK_PREFIX}${ux_specification_types_1.DefinitionName.HeaderActionV4}`,
|
|
36
|
+
description: common_1.getDataFieldDescription(item, entityType)
|
|
32
37
|
});
|
|
33
|
-
headerAction[
|
|
34
|
-
headerAction[
|
|
35
|
-
|
|
38
|
+
headerAction[ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
39
|
+
headerAction[ux_specification_types_1.SchemaTag.keys] = [{ name: ux_specification_types_1.SchemaKeyName.action, value: actionName }];
|
|
40
|
+
if (namespace) {
|
|
41
|
+
appSchema.definitions[actionDefinitionKey][ux_specification_types_1.SchemaTag.target] = namespace;
|
|
42
|
+
}
|
|
43
|
+
headerAction[ux_specification_types_1.SchemaTag.annotationPath] = `/${convertedIdentification}/${index}`;
|
|
44
|
+
headerActions.properties[stableId] = {
|
|
45
|
+
$ref: `${common_1.DEFINITION_LINK_PREFIX}${actionDefinitionKey}`
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Callback for adding a single action to footerActions of V4
|
|
52
|
+
* @param {EntityType} entityType - current entity type
|
|
53
|
+
* @param {Definition} appSchema Schema of the app
|
|
54
|
+
* @param {Definition} footerActions - list of footer actions, to be enhanced
|
|
55
|
+
* @param {String} convertedIdentification - converted UI.Identification term
|
|
56
|
+
*/
|
|
57
|
+
function addFooterActionCallBackV4(entityType, appSchema, footerActions, convertedIdentification) {
|
|
58
|
+
return (item, index) => {
|
|
59
|
+
if (item['Determining'] && item.$Type === "com.sap.vocabularies.UI.v1.DataFieldForAction" /* DataFieldForAction */) {
|
|
60
|
+
const actionId = StableIdHelper_1.getStableIdPartFromDataField(item);
|
|
61
|
+
const description = common_1.getDataFieldDescription(item, entityType);
|
|
62
|
+
const actionDefinitionKey = common_1.prepareRef(`${ux_specification_types_1.DefinitionName.ObjectPageFooterAction}<${actionId}>`);
|
|
63
|
+
appSchema.definitions[actionDefinitionKey] = {
|
|
64
|
+
type: 'object',
|
|
65
|
+
$ref: `${common_1.DEFINITION_LINK_PREFIX}${ux_specification_types_1.DefinitionName.FooterActionV4}`,
|
|
66
|
+
description: description
|
|
67
|
+
};
|
|
68
|
+
appSchema.definitions[actionDefinitionKey][ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
69
|
+
appSchema.definitions[actionDefinitionKey][ux_specification_types_1.SchemaTag.annotationPath] = `/${convertedIdentification}/${index}`;
|
|
70
|
+
footerActions.properties[actionId] = {
|
|
36
71
|
$ref: `${common_1.DEFINITION_LINK_PREFIX}${actionDefinitionKey}`
|
|
37
72
|
};
|
|
38
73
|
}
|
|
@@ -48,21 +83,21 @@ function addHeaderActionCallBackV4(entityType, appSchema, actionAnnotation, head
|
|
|
48
83
|
*/
|
|
49
84
|
function addCustomColumnsOP(appSchema, v4Page, lineItemId, facetIdInManifest, logger) {
|
|
50
85
|
// Create type specific copy of 'TableCustomColumnOP'
|
|
51
|
-
const useDefinitionAsKey = lineItemId !==
|
|
86
|
+
const useDefinitionAsKey = lineItemId !== ux_specification_types_1.DefinitionName.LineItems &&
|
|
52
87
|
lineItemId !== 'LineItemsOfSPV::LineItem' &&
|
|
53
88
|
lineItemId !== '@com.sap.vocabularies.UI.v1.LineItem';
|
|
54
89
|
const customColumDefinitionKey = useDefinitionAsKey
|
|
55
|
-
? `${
|
|
56
|
-
:
|
|
90
|
+
? `${ux_specification_types_1.DefinitionName.CustomColumnOP}<${lineItemId}>`
|
|
91
|
+
: ux_specification_types_1.DefinitionName.CustomColumnOP;
|
|
57
92
|
const customColumnDefinition = appSchema.definitions[customColumDefinitionKey];
|
|
58
|
-
customColumnDefinition[
|
|
93
|
+
customColumnDefinition[ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
59
94
|
customColumnDefinition.description = 'Custom Column';
|
|
60
95
|
// Update definitions for type specific custom columns
|
|
61
|
-
const schemaId = `${
|
|
96
|
+
const schemaId = `${ux_specification_types_1.DefinitionName.CustomColumnOP}<${lineItemId}>`;
|
|
62
97
|
utils_1.addCustomColumnDefinition(appSchema, v4Page, logger, schemaId, lineItemId, facetIdInManifest);
|
|
63
|
-
const facetKey = useDefinitionAsKey ? lineItemId :
|
|
64
|
-
common_1.parseSchemaDefinition(
|
|
65
|
-
const positionId = useDefinitionAsKey ? `${
|
|
98
|
+
const facetKey = useDefinitionAsKey ? lineItemId : ux_specification_types_1.DefinitionName.PositionOP;
|
|
99
|
+
common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.PositionOP, facetKey, appSchema, useDefinitionAsKey);
|
|
100
|
+
const positionId = useDefinitionAsKey ? `${ux_specification_types_1.DefinitionName.PositionOP}<${lineItemId}>` : ux_specification_types_1.DefinitionName.PositionOP;
|
|
66
101
|
customColumnDefinition.properties.position.$ref = `${common_1.DEFINITION_LINK_PREFIX}${positionId}`;
|
|
67
102
|
utils_1.addFragmentEnumForAnchor(appSchema, lineItemId, v4Page, positionId, facetIdInManifest.replace(/::/g, '/'));
|
|
68
103
|
}
|
|
@@ -76,27 +111,60 @@ function addCustomColumnsOP(appSchema, v4Page, lineItemId, facetIdInManifest, lo
|
|
|
76
111
|
*/
|
|
77
112
|
function addCustomActionsOP(appSchema, v4Page, lineItemId, facetIdInManifest, logger) {
|
|
78
113
|
// Create type specific copy of 'TableCustomActionOP'
|
|
79
|
-
const useDefinitionAsKey = lineItemId !==
|
|
114
|
+
const useDefinitionAsKey = lineItemId !== ux_specification_types_1.DefinitionName.LineItems &&
|
|
80
115
|
lineItemId !== 'LineItemsOfSPV::LineItem' &&
|
|
81
116
|
lineItemId !== '@com.sap.vocabularies.UI.v1.LineItem';
|
|
82
117
|
const customActionDefinitionKey = useDefinitionAsKey
|
|
83
|
-
? `${
|
|
84
|
-
:
|
|
118
|
+
? `${ux_specification_types_1.DefinitionName.CustomTableActionOP}<${lineItemId}>`
|
|
119
|
+
: ux_specification_types_1.DefinitionName.CustomTableActionOP;
|
|
85
120
|
const customActionDefinition = appSchema.definitions[customActionDefinitionKey];
|
|
86
|
-
customActionDefinition[
|
|
121
|
+
customActionDefinition[ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
87
122
|
customActionDefinition.description = 'Custom Action';
|
|
88
123
|
// Update definitions for type specific custom columns
|
|
89
|
-
const schemaId = `${
|
|
90
|
-
const schemaIdForActions = `${
|
|
124
|
+
const schemaId = `${ux_specification_types_1.DefinitionName.CustomTableActionOP}<${lineItemId}>`;
|
|
125
|
+
const schemaIdForActions = `${ux_specification_types_1.DefinitionName.Actions}<${common_1.prepareRef(lineItemId)}>`;
|
|
126
|
+
utils_1.addCustomActionDefinition(appSchema, v4Page, logger, schemaId, schemaIdForActions, facetIdInManifest);
|
|
127
|
+
const facetKey = useDefinitionAsKey ? lineItemId : ux_specification_types_1.DefinitionName.CustomActionPositionOP;
|
|
128
|
+
common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.CustomActionPositionOP, facetKey, appSchema, useDefinitionAsKey);
|
|
129
|
+
// Anchor selection
|
|
130
|
+
const positionId = useDefinitionAsKey
|
|
131
|
+
? `${ux_specification_types_1.DefinitionName.CustomActionPositionOP}<${lineItemId}>`
|
|
132
|
+
: ux_specification_types_1.DefinitionName.CustomActionPositionOP;
|
|
133
|
+
customActionDefinition.properties.position.$ref = `${common_1.DEFINITION_LINK_PREFIX}${positionId}`;
|
|
134
|
+
utils_1.addEnumForActionAnchor(appSchema, schemaIdForActions, positionId);
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* Object Page specific enhancements to handleFormIdentification
|
|
138
|
+
* @param {object} appSchema App schema in general
|
|
139
|
+
* @param {SapUiAppPageV4} v4Page Current page in manifest
|
|
140
|
+
* @param {string} formItemId - identifier of the current form in schema
|
|
141
|
+
* @param {string} facetIdInManifest - identifier of the current object page section in manifest
|
|
142
|
+
* @param {ExtensionLogger} logger - logger for exceptions
|
|
143
|
+
*/
|
|
144
|
+
function addFormCustomActionsOP(appSchema, v4Page, formItemId, facetIdInManifest, logger) {
|
|
145
|
+
const useDefinitionAsKey = true;
|
|
146
|
+
const customActionDefinitionKey = useDefinitionAsKey
|
|
147
|
+
? `${ux_specification_types_1.DefinitionName.CustomFormActionOP}<${formItemId}>`
|
|
148
|
+
: ux_specification_types_1.DefinitionName.CustomFormActionOP;
|
|
149
|
+
const customActionDefinition = appSchema.definitions[customActionDefinitionKey];
|
|
150
|
+
customActionDefinition[ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
151
|
+
customActionDefinition.description = 'Custom Action';
|
|
152
|
+
const schemaId = `${ux_specification_types_1.DefinitionName.CustomFormActionOP}<${formItemId}>`;
|
|
153
|
+
const schemaIdForActions = `${ux_specification_types_1.DefinitionName.SectionActions}<${common_1.prepareRef(formItemId)}>`;
|
|
91
154
|
utils_1.addCustomActionDefinition(appSchema, v4Page, logger, schemaId, schemaIdForActions, facetIdInManifest);
|
|
92
|
-
const facetKey = useDefinitionAsKey ?
|
|
93
|
-
common_1.parseSchemaDefinition(
|
|
155
|
+
const facetKey = useDefinitionAsKey ? formItemId : ux_specification_types_1.DefinitionName.CustomActionPositionOP;
|
|
156
|
+
common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.CustomActionPositionOP, facetKey, appSchema, useDefinitionAsKey);
|
|
94
157
|
// Anchor selection
|
|
95
158
|
const positionId = useDefinitionAsKey
|
|
96
|
-
? `${
|
|
97
|
-
:
|
|
159
|
+
? `${ux_specification_types_1.DefinitionName.CustomActionPositionOP}<${formItemId}>`
|
|
160
|
+
: ux_specification_types_1.DefinitionName.CustomActionPositionOP;
|
|
98
161
|
customActionDefinition.properties.position.$ref = `${common_1.DEFINITION_LINK_PREFIX}${positionId}`;
|
|
99
162
|
utils_1.addEnumForActionAnchor(appSchema, schemaIdForActions, positionId);
|
|
163
|
+
if (appSchema.definitions[schemaIdForActions]) {
|
|
164
|
+
appSchema.definitions[schemaIdForActions].additionalProperties = {
|
|
165
|
+
$ref: `${common_1.DEFINITION_LINK_PREFIX}${customActionDefinitionKey}`
|
|
166
|
+
};
|
|
167
|
+
}
|
|
100
168
|
}
|
|
101
169
|
/**
|
|
102
170
|
* Adds definitions for line items in object page sections to the app schema
|
|
@@ -112,20 +180,20 @@ function handleLineItem(facet, facetKey, appSchema, lineItemFacet, oDataServiceA
|
|
|
112
180
|
const lineItemId = common_1.getFacetKeyInSchema(facetKey);
|
|
113
181
|
const index = facetKey.lastIndexOf('::');
|
|
114
182
|
const annotation = index > -1 ? facetKey.substring(index + 2) : facetKey;
|
|
115
|
-
const tableDefinition = common_1.parseSchemaDefinition(
|
|
183
|
+
const tableDefinition = common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.ObjectPageTable, facetKey, appSchema);
|
|
116
184
|
if (facet.entityType && annotation) {
|
|
117
|
-
tableDefinition[
|
|
185
|
+
tableDefinition[ux_specification_types_1.SchemaTag.annotationPath] = `/${facet.entityType.fullyQualifiedName}/${annotation}`;
|
|
118
186
|
}
|
|
119
187
|
tableDefinition.properties.columns = {
|
|
120
188
|
$ref: `${common_1.DEFINITION_LINK_PREFIX}${lineItemId}`
|
|
121
189
|
};
|
|
122
|
-
tableDefinition.properties.toolBar.$ref = common_1.getFacetDefinitionLink(
|
|
190
|
+
tableDefinition.properties.toolBar.$ref = common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.ObjectPageToolBar, facetKey);
|
|
123
191
|
//adjust quickVariantSelection
|
|
124
|
-
tableDefinition.properties.quickVariantSelection.$ref = common_1.getFacetDefinitionLink(
|
|
125
|
-
const tableQVS = common_1.parseSchemaDefinition(
|
|
126
|
-
tableQVS.properties.paths['items'].$ref = common_1.getFacetDefinitionLink(
|
|
127
|
-
common_1.parseSchemaDefinition(
|
|
128
|
-
common_1.addEnumForSingleTabVariant(facet.entityType, appSchema, `${
|
|
192
|
+
tableDefinition.properties.quickVariantSelection.$ref = common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.QuickVariantSelectionV4OP, facetKey);
|
|
193
|
+
const tableQVS = common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.QuickVariantSelectionV4OP, facetKey, appSchema);
|
|
194
|
+
tableQVS.properties.paths['items'].$ref = common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.AnnotationPathAsObject, facetKey);
|
|
195
|
+
common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.AnnotationPathAsObject, facetKey, appSchema);
|
|
196
|
+
common_1.addEnumForSingleTabVariant(facet.entityType, appSchema, `${ux_specification_types_1.DefinitionName.AnnotationPathAsObject}<${lineItemId}>`);
|
|
129
197
|
const dataForLineItem = {
|
|
130
198
|
appSchema,
|
|
131
199
|
lineItemAnnotation: lineItemFacet['target'],
|
|
@@ -133,7 +201,7 @@ function handleLineItem(facet, facetKey, appSchema, lineItemFacet, oDataServiceA
|
|
|
133
201
|
oDataServiceAVT,
|
|
134
202
|
lineItemId
|
|
135
203
|
};
|
|
136
|
-
utils_1.addLineItemsTypeToSchema(dataForLineItem,
|
|
204
|
+
utils_1.addLineItemsTypeToSchema(dataForLineItem, ux_specification_types_1.DefinitionName.ObjectPageTableColumn, ux_specification_types_1.DefinitionName.CustomColumnOP, ux_specification_types_1.DefinitionName.CustomTableActionOP);
|
|
137
205
|
addCustomColumnsOP(appSchema, v4Page, lineItemId, facetKey, logger);
|
|
138
206
|
addCustomActionsOP(appSchema, v4Page, lineItemId, facetKey, logger);
|
|
139
207
|
return tableDefinition;
|
|
@@ -152,31 +220,34 @@ function handleLineItem(facet, facetKey, appSchema, lineItemFacet, oDataServiceA
|
|
|
152
220
|
function handleSectionTable(facet, facetKey, appSchema, lineItemFacet, generateParameters, v4Page, sections) {
|
|
153
221
|
if (sections) {
|
|
154
222
|
sections.properties[facetKey] = {
|
|
155
|
-
$ref: common_1.getFacetDefinitionLink(
|
|
223
|
+
$ref: common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.ObjectPageSectionTableV4, facetKey)
|
|
156
224
|
};
|
|
157
225
|
}
|
|
158
|
-
const sectionTable = common_1.parseSchemaDefinition(
|
|
226
|
+
const sectionTable = common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.ObjectPageSectionTableV4, facetKey, appSchema);
|
|
159
227
|
common_1.addSectionTitleAndDescription(facet, sectionTable, common_1.getFacetKeyInSchema(facetKey));
|
|
160
|
-
sectionTable[
|
|
161
|
-
sectionTable.
|
|
228
|
+
sectionTable[ux_specification_types_1.SchemaTag.annotationPath] = facet.annotationPath;
|
|
229
|
+
sectionTable[ux_specification_types_1.SchemaTag.target] = facet.namespace;
|
|
230
|
+
sectionTable.properties.table['$ref'] = common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.ObjectPageTable, facetKey);
|
|
162
231
|
const table = handleLineItem(facet, facetKey, appSchema, lineItemFacet, generateParameters.serviceAVT, v4Page, generateParameters.logger);
|
|
163
232
|
return { sectionTable, table };
|
|
164
233
|
}
|
|
165
234
|
/**
|
|
166
235
|
* Adds definitions for Identification and Form facet items in object page sections to the app schema
|
|
167
|
-
* @param {FacetConfig} facet - current facet
|
|
168
|
-
* @param {
|
|
169
|
-
* @param {
|
|
170
|
-
* @param {object}
|
|
236
|
+
* @param {FacetConfig} facet - current facet
|
|
237
|
+
* @param {v4.SapUiAppPageV4} v4Page Current page in manifest
|
|
238
|
+
* @param {string} facetKey - facet key
|
|
239
|
+
* @param {object} sections - schema of current sections definition
|
|
240
|
+
* @param {object} appSchema - app specific schema that potentially gets enhanced
|
|
171
241
|
* @param {SectionType} sectionPrefix - prefix to distinguish Section and HeaderSection
|
|
242
|
+
* @param {ExtensionLogger} logger - logger for exceptions
|
|
172
243
|
*/
|
|
173
|
-
function handleFormIdentification(facet, facetKey, sections, appSchema, sectionPrefix) {
|
|
244
|
+
function handleFormIdentification(facet, v4Page, facetKey, sections, appSchema, sectionPrefix, logger) {
|
|
174
245
|
let definitionType;
|
|
175
246
|
if (sectionPrefix === ux_specification_types_1.SectionType.Section) {
|
|
176
|
-
definitionType =
|
|
247
|
+
definitionType = ux_specification_types_1.DefinitionName.ObjectPageSectionForm;
|
|
177
248
|
}
|
|
178
249
|
else if (sectionPrefix === ux_specification_types_1.SectionType.HeaderSection) {
|
|
179
|
-
definitionType =
|
|
250
|
+
definitionType = ux_specification_types_1.DefinitionName.ObjectPageHeaderSectionForm;
|
|
180
251
|
}
|
|
181
252
|
sections['properties'][facetKey] = {
|
|
182
253
|
$ref: common_1.getFacetDefinitionLink(definitionType, facetKey)
|
|
@@ -186,10 +257,15 @@ function handleFormIdentification(facet, facetKey, sections, appSchema, sectionP
|
|
|
186
257
|
formSection.properties = {};
|
|
187
258
|
}
|
|
188
259
|
common_1.addSectionTitleAndDescription(facet, formSection, facetKey);
|
|
189
|
-
formSection[
|
|
190
|
-
formSection[
|
|
191
|
-
|
|
192
|
-
common_1.handleForm(sectionPrefix, facet, formSection, appSchema, ux_specification_types_1.FioriElementsVersion.v4,
|
|
260
|
+
formSection[ux_specification_types_1.SchemaTag.annotationPath] = facet.annotationPath;
|
|
261
|
+
formSection[ux_specification_types_1.SchemaTag.target] = facet.namespace;
|
|
262
|
+
formSection[ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
263
|
+
const targetId = common_1.handleForm(sectionPrefix, facet, formSection, appSchema, ux_specification_types_1.FioriElementsVersion.v4, facetKey);
|
|
264
|
+
if (facet.base === ux_specification_types_1.FacetBase.Form) {
|
|
265
|
+
const formItemId = common_1.getFacetKeyInSchema(facetKey);
|
|
266
|
+
common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.CustomFormActionOP, targetId, appSchema);
|
|
267
|
+
addFormCustomActionsOP(appSchema, v4Page, targetId, formItemId, logger);
|
|
268
|
+
}
|
|
193
269
|
}
|
|
194
270
|
/**
|
|
195
271
|
* Adds definitions for header sections (DataPoint, Chart) in object page sections to the app schema
|
|
@@ -203,11 +279,12 @@ function handleHeaderFacet(facet, facetKey, sections, appSchema, facetDefinition
|
|
|
203
279
|
sections['properties'][facetKey] = {
|
|
204
280
|
$ref: `${common_1.DEFINITION_LINK_PREFIX}${facetDefinitionKey}`
|
|
205
281
|
};
|
|
206
|
-
const sectionFacet = common_1.parseSchemaDefinition(
|
|
282
|
+
const sectionFacet = common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.CommonHeaderFacetSettings, facetDefinitionKey, appSchema, false);
|
|
207
283
|
common_1.addTargetTitleAndSectionDescription(facet, sectionFacet, facetKey);
|
|
208
|
-
sectionFacet[
|
|
209
|
-
sectionFacet[
|
|
210
|
-
sectionFacet[
|
|
284
|
+
sectionFacet[ux_specification_types_1.SchemaTag.annotationPath] = facet.annotationPath;
|
|
285
|
+
sectionFacet[ux_specification_types_1.SchemaTag.target] = facet.namespace;
|
|
286
|
+
sectionFacet[ux_specification_types_1.SchemaTag.dataType] = common_1.determineDataTypeOfTarget(facet?.target);
|
|
287
|
+
sectionFacet[ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
211
288
|
}
|
|
212
289
|
/**
|
|
213
290
|
* Adds definitions for Chart items in object page sections to the app schema
|
|
@@ -217,24 +294,24 @@ function handleHeaderFacet(facet, facetKey, sections, appSchema, facetDefinition
|
|
|
217
294
|
* @param {EntityType} entityType - current entity type
|
|
218
295
|
*/
|
|
219
296
|
function handleChartActions(facet, facetKey, appSchema, entityType) {
|
|
220
|
-
const actions = common_1.parseSchemaDefinition(
|
|
297
|
+
const actions = common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.ObjectPageToolBarActions, facetKey, appSchema);
|
|
221
298
|
actions.additionalProperties = false;
|
|
222
299
|
actions.properties = {};
|
|
223
300
|
if (facet.Actions) {
|
|
224
301
|
let i = 0;
|
|
225
302
|
facet.Actions.forEach((actionRecord) => {
|
|
226
303
|
const description = common_1.getDataFieldDescription(actionRecord, entityType);
|
|
227
|
-
const prefix = actionRecord.$Type.split(
|
|
304
|
+
const prefix = actionRecord.$Type.split(ux_specification_types_1.UIVOCABULARYDOT)[1];
|
|
228
305
|
const actionId = actionRecord.Action.replace('/', '??');
|
|
229
306
|
const toolBarActionsProperty = (actions.properties[`${prefix}::${actionRecord.Action}`] = {
|
|
230
|
-
$ref: common_1.getFacetDefinitionLink(
|
|
307
|
+
$ref: common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.ObjectPageToolBarAction, actionId),
|
|
231
308
|
description
|
|
232
309
|
});
|
|
233
|
-
toolBarActionsProperty[
|
|
234
|
-
toolBarActionsProperty[
|
|
235
|
-
const toolBarAction = common_1.parseSchemaDefinition(
|
|
236
|
-
toolBarAction[
|
|
237
|
-
toolBarAction[
|
|
310
|
+
toolBarActionsProperty[ux_specification_types_1.SchemaTag.propertyIndex] = i;
|
|
311
|
+
toolBarActionsProperty[ux_specification_types_1.SchemaTag.annotationType] = actionRecord.$Type;
|
|
312
|
+
const toolBarAction = common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.ObjectPageToolBarAction, common_1.prepareRef(actionId), appSchema);
|
|
313
|
+
toolBarAction[ux_specification_types_1.SchemaTag.annotationPath] = common_1.getFacetAnnotationPath(actionRecord);
|
|
314
|
+
toolBarAction[ux_specification_types_1.SchemaTag.dataType] = common_1.determineDataType(actionRecord);
|
|
238
315
|
toolBarAction.properties = {};
|
|
239
316
|
i++;
|
|
240
317
|
});
|
|
@@ -249,16 +326,16 @@ function handleChartActions(facet, facetKey, appSchema, entityType) {
|
|
|
249
326
|
* @param {EntityType} entityType - current entity type
|
|
250
327
|
*/
|
|
251
328
|
function handleChart(facet, facetKey, appSchema, entityType) {
|
|
252
|
-
const chart = common_1.parseSchemaDefinition(
|
|
329
|
+
const chart = common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.ObjectPageChart, facetKey, appSchema);
|
|
253
330
|
if (facet['Title']) {
|
|
254
331
|
chart.description = facet['Title'];
|
|
255
332
|
}
|
|
256
|
-
chart[
|
|
257
|
-
chart[
|
|
258
|
-
chart[
|
|
259
|
-
chart.properties.toolBar['$ref'] = common_1.getFacetDefinitionLink(
|
|
260
|
-
const chartToolBar = common_1.parseSchemaDefinition(
|
|
261
|
-
chartToolBar.properties.actions['$ref'] = common_1.getFacetDefinitionLink(
|
|
333
|
+
chart[ux_specification_types_1.SchemaTag.annotationPath] = common_1.getFacetAnnotationPath(facet);
|
|
334
|
+
chart[ux_specification_types_1.SchemaTag.dataType] = common_1.determineDataTypeOfTarget(facet.target || facet);
|
|
335
|
+
chart[ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
336
|
+
chart.properties.toolBar['$ref'] = common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.ObjectPageToolBar, facetKey);
|
|
337
|
+
const chartToolBar = common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.ObjectPageToolBar, facetKey, appSchema);
|
|
338
|
+
chartToolBar.properties.actions['$ref'] = common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.ObjectPageToolBarActions, facetKey);
|
|
262
339
|
const chartActions = handleChartActions(facet, facetKey, appSchema, entityType);
|
|
263
340
|
return { chart, chartActions };
|
|
264
341
|
}
|
|
@@ -273,13 +350,13 @@ function handleChart(facet, facetKey, appSchema, entityType) {
|
|
|
273
350
|
function handleSectionChart(facet, facetKey, appSchema, sections, entityType = facet.entityType) {
|
|
274
351
|
if (sections) {
|
|
275
352
|
sections.properties[facetKey] = {
|
|
276
|
-
$ref: common_1.getFacetDefinitionLink(
|
|
353
|
+
$ref: common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.ObjectPageSectionChart, facetKey)
|
|
277
354
|
};
|
|
278
355
|
}
|
|
279
|
-
const sectionChart = common_1.parseSchemaDefinition(
|
|
356
|
+
const sectionChart = common_1.parseSchemaDefinition(ux_specification_types_1.DefinitionName.ObjectPageSectionChart, facetKey, appSchema);
|
|
280
357
|
common_1.addTargetTitleAndSectionDescription(facet, sectionChart, facetKey);
|
|
281
|
-
sectionChart[
|
|
282
|
-
sectionChart.properties.chart['$ref'] = common_1.getFacetDefinitionLink(
|
|
358
|
+
sectionChart[ux_specification_types_1.SchemaTag.annotationPath] = common_1.getFacetAnnotationPath(facet);
|
|
359
|
+
sectionChart.properties.chart['$ref'] = common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.ObjectPageChart, facetKey);
|
|
283
360
|
const { chart, chartActions } = handleChart(facet.target || facet, facetKey, appSchema, entityType);
|
|
284
361
|
return { sectionChart, chart, chartActions };
|
|
285
362
|
}
|
|
@@ -311,32 +388,68 @@ function handleSectionPresentationVariant(facet, facetKey, appSchema, sections,
|
|
|
311
388
|
return prop.name === navPath;
|
|
312
389
|
});
|
|
313
390
|
const targetType = navigationProp.targetType;
|
|
314
|
-
target = targetType.annotations.UI[visualizationKey.split(
|
|
391
|
+
target = targetType.annotations.UI[visualizationKey.split(ux_specification_types_1.UIVOCABULARYDOT)[1]];
|
|
315
392
|
}
|
|
316
393
|
}
|
|
317
394
|
if (facetTarget) {
|
|
318
|
-
const visualizationType = visualizationKey.split(
|
|
319
|
-
const namespace = facet.target[
|
|
395
|
+
const visualizationType = visualizationKey.split(ux_specification_types_1.UIVOCABULARYDOT)[1];
|
|
396
|
+
const namespace = facet.target[ux_specification_types_1.SchemaTag.fullyQualifiedName].split('@')[0];
|
|
320
397
|
const fullVisualizationKey = navPath ? `${navPath}::${visualizationKey}` : visualizationKey;
|
|
321
398
|
if (visualizationType.startsWith(ux_specification_types_1.Visualization.Chart)) {
|
|
322
399
|
sections.properties[`${facetKey}<${visualizationKey}>`] = {
|
|
323
|
-
$ref: common_1.getFacetDefinitionLink(
|
|
400
|
+
$ref: common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.ObjectPageSectionChart, fullVisualizationKey)
|
|
324
401
|
};
|
|
325
402
|
const { sectionChart, chart } = handleSectionChart(facetTarget, fullVisualizationKey, appSchema, undefined, facet.entityType);
|
|
326
|
-
sectionChart[
|
|
403
|
+
sectionChart[ux_specification_types_1.SchemaTag.annotationPath] = facet.annotationPath;
|
|
327
404
|
common_1.addTargetTitleAndSectionDescription(facet, sectionChart, facetKey);
|
|
328
|
-
chart[
|
|
405
|
+
chart[ux_specification_types_1.SchemaTag.annotationPath] = `/${namespace}/${visualizationKey}`;
|
|
406
|
+
chart[ux_specification_types_1.SchemaTag.target] = namespace;
|
|
329
407
|
}
|
|
330
408
|
else if (visualizationType.startsWith(ux_specification_types_1.Visualization.LineItem)) {
|
|
331
409
|
sections.properties[`${facetKey}<${visualizationKey}>`] = {
|
|
332
|
-
$ref: common_1.getFacetDefinitionLink(
|
|
410
|
+
$ref: common_1.getFacetDefinitionLink(ux_specification_types_1.DefinitionName.ObjectPageSectionTableV4, fullVisualizationKey)
|
|
333
411
|
};
|
|
334
412
|
const { sectionTable, table } = handleSectionTable(facet, fullVisualizationKey, appSchema, { target, entityType: facet.entityType }, generateParameters, v4Page);
|
|
335
|
-
sectionTable[
|
|
413
|
+
sectionTable[ux_specification_types_1.SchemaTag.annotationPath] = facet.annotationPath;
|
|
336
414
|
common_1.addTargetTitleAndSectionDescription(facet, sectionTable, facetKey);
|
|
337
|
-
delete sectionTable[
|
|
338
|
-
table[
|
|
415
|
+
delete sectionTable[ux_specification_types_1.SchemaTag.isViewNode];
|
|
416
|
+
table[ux_specification_types_1.SchemaTag.annotationPath] = `/${namespace}/${visualizationKey}`;
|
|
417
|
+
table[ux_specification_types_1.SchemaTag.target] = namespace;
|
|
418
|
+
}
|
|
419
|
+
}
|
|
420
|
+
}
|
|
421
|
+
/**
|
|
422
|
+
* Adds definitions for collections in object page sections to the app schema
|
|
423
|
+
* @param {FacetConfig} facet - the given facet from the UI annotations
|
|
424
|
+
* @param {string} facetKey - key of the facet, as used in annotation
|
|
425
|
+
* @param {Definition} appSchema - app schema in general
|
|
426
|
+
* @param {Definition} sections - schema of current sections definition.
|
|
427
|
+
* @param {SectionType} sectionPrefix - prefix to distinguish Section and HeaderSection
|
|
428
|
+
* @param {GenerateSchemaParameters} generateParameters - list of API input parameters
|
|
429
|
+
* @param {SapUiAppPageV4} v4Page Current page in manifest
|
|
430
|
+
*/
|
|
431
|
+
function handleCollection(facet, facetKey, appSchema, sections, sectionPrefix, generateParameters, v4Page) {
|
|
432
|
+
const collectionFacet = (sections.properties[facetKey] = common_1.createDefaultSection(appSchema, facet, facetKey));
|
|
433
|
+
collectionFacet.properties = {
|
|
434
|
+
subsections: {
|
|
435
|
+
additionalProperties: false,
|
|
436
|
+
type: 'object',
|
|
437
|
+
properties: {},
|
|
438
|
+
description: 'Subsections'
|
|
439
|
+
}
|
|
440
|
+
};
|
|
441
|
+
const subSections = collectionFacet.properties.subsections;
|
|
442
|
+
subSections[ux_specification_types_1.SchemaTag.annotationPath] = facet.annotationPath;
|
|
443
|
+
subSections[ux_specification_types_1.SchemaTag.target] = facet.namespace;
|
|
444
|
+
subSections[ux_specification_types_1.SchemaTag.keys] = [
|
|
445
|
+
{
|
|
446
|
+
name: ux_specification_types_1.SchemaKeyName.id,
|
|
447
|
+
value: facet.ID
|
|
339
448
|
}
|
|
449
|
+
];
|
|
450
|
+
subSections[ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
451
|
+
for (const key in facet.facets) {
|
|
452
|
+
addSection(generateParameters, facet.facets, key, subSections, appSchema, sectionPrefix, v4Page);
|
|
340
453
|
}
|
|
341
454
|
}
|
|
342
455
|
/**
|
|
@@ -353,31 +466,31 @@ function addSection(generateParameters, facets, facetKey, sections, appSchema, s
|
|
|
353
466
|
const facet = facets[facetKey];
|
|
354
467
|
const facetDefinitionKey = `ObjectPage${sectionPrefix}${facet.base}<${common_1.getFacetKeyInSchema(facetKey)}>`;
|
|
355
468
|
switch (facet.base) {
|
|
356
|
-
case
|
|
469
|
+
case ux_specification_types_1.FacetBase.PresentationVariant: {
|
|
357
470
|
handleSectionPresentationVariant(facet, facetKey, appSchema, sections, generateParameters, v4Page);
|
|
358
471
|
break;
|
|
359
472
|
}
|
|
360
|
-
case
|
|
473
|
+
case ux_specification_types_1.FacetBase.CollectionFacet: {
|
|
361
474
|
handleCollection(facet, facetKey, appSchema, sections, sectionPrefix, generateParameters, v4Page);
|
|
362
475
|
break;
|
|
363
476
|
}
|
|
364
|
-
case
|
|
477
|
+
case ux_specification_types_1.FacetBase.LineItem: {
|
|
365
478
|
if (sectionPrefix === ux_specification_types_1.SectionType.Section) {
|
|
366
479
|
const lineItemFacet = facets[facetKey];
|
|
367
480
|
handleSectionTable(facet, facetKey, appSchema, lineItemFacet, generateParameters, v4Page, sections);
|
|
368
481
|
}
|
|
369
482
|
break;
|
|
370
483
|
}
|
|
371
|
-
case
|
|
372
|
-
case
|
|
373
|
-
handleFormIdentification(facet, facetKey, sections, appSchema, sectionPrefix);
|
|
484
|
+
case ux_specification_types_1.FacetBase.Form:
|
|
485
|
+
case ux_specification_types_1.FacetBase.Identification: {
|
|
486
|
+
handleFormIdentification(facet, v4Page, facetKey, sections, appSchema, sectionPrefix, generateParameters.logger);
|
|
374
487
|
break;
|
|
375
488
|
}
|
|
376
|
-
case
|
|
489
|
+
case ux_specification_types_1.FacetBase.DataPoint: {
|
|
377
490
|
handleHeaderFacet(facet, facetKey, sections, appSchema, facetDefinitionKey);
|
|
378
491
|
break;
|
|
379
492
|
}
|
|
380
|
-
case
|
|
493
|
+
case ux_specification_types_1.FacetBase.Chart: {
|
|
381
494
|
if (sectionPrefix === ux_specification_types_1.SectionType.HeaderSection) {
|
|
382
495
|
handleHeaderFacet(facet, facetKey, sections, appSchema, facetDefinitionKey);
|
|
383
496
|
}
|
|
@@ -386,8 +499,8 @@ function addSection(generateParameters, facets, facetKey, sections, appSchema, s
|
|
|
386
499
|
}
|
|
387
500
|
break;
|
|
388
501
|
}
|
|
389
|
-
case
|
|
390
|
-
case
|
|
502
|
+
case ux_specification_types_1.FacetBase.Address:
|
|
503
|
+
case ux_specification_types_1.FacetBase.Contact: {
|
|
391
504
|
common_1.handleAddressContact(facet, facetKey, sections, appSchema, sectionPrefix);
|
|
392
505
|
break;
|
|
393
506
|
}
|
|
@@ -396,33 +509,6 @@ function addSection(generateParameters, facets, facetKey, sections, appSchema, s
|
|
|
396
509
|
}
|
|
397
510
|
}
|
|
398
511
|
}
|
|
399
|
-
/**
|
|
400
|
-
* Adds definitions for collections in object page sections to the app schema
|
|
401
|
-
* @param {FacetConfig} facet - the given facet from the UI annotations
|
|
402
|
-
* @param {string} facetKey - key of the facet, as used in annotation
|
|
403
|
-
* @param {Definition} appSchema - app schema in general
|
|
404
|
-
* @param {Definition} sections - schema of current sections definition.
|
|
405
|
-
* @param {SectionType} sectionPrefix - prefix to distinguish Section and HeaderSection
|
|
406
|
-
* @param {GenerateSchemaParameters} generateParameters - list of API input parameters
|
|
407
|
-
* @param {SapUiAppPageV4} v4Page Current page in manifest
|
|
408
|
-
*/
|
|
409
|
-
function handleCollection(facet, facetKey, appSchema, sections, sectionPrefix, generateParameters, v4Page) {
|
|
410
|
-
const collectionFacet = (sections.properties[facetKey] = common_1.createDefaultSection(appSchema, facet, facetKey));
|
|
411
|
-
collectionFacet.properties = {
|
|
412
|
-
subsections: {
|
|
413
|
-
additionalProperties: false,
|
|
414
|
-
type: 'object',
|
|
415
|
-
properties: {},
|
|
416
|
-
description: 'Subsections'
|
|
417
|
-
}
|
|
418
|
-
};
|
|
419
|
-
const subSections = collectionFacet.properties.subsections;
|
|
420
|
-
subSections[common_1.SchemaTag.annotationPath] = facet.annotationPath;
|
|
421
|
-
subSections[common_1.SchemaTag.isViewNode] = true;
|
|
422
|
-
for (const key in facet.facets) {
|
|
423
|
-
addSection(generateParameters, facet.facets, key, subSections, appSchema, sectionPrefix, v4Page);
|
|
424
|
-
}
|
|
425
|
-
}
|
|
426
512
|
/**
|
|
427
513
|
* Derives the sections from the UI.Facets annotation and adds them to the schema
|
|
428
514
|
* @param {GenerateAppSchemaParameters} generateParameters - list of API input parameters
|
|
@@ -433,18 +519,18 @@ function addSections(generateParameters, appSchema, v4Page) {
|
|
|
433
519
|
// Get facet annotations
|
|
434
520
|
const facets = common_1.getObjectPageFacets(generateParameters.entitySet.entityType, generateParameters.serviceAVT, ux_specification_types_1.FioriElementsVersion.v4, generateParameters.logger);
|
|
435
521
|
if (!facets) {
|
|
436
|
-
delete appSchema.definitions[
|
|
522
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageSubSections];
|
|
437
523
|
return;
|
|
438
524
|
}
|
|
439
|
-
const sections = appSchema.definitions[
|
|
525
|
+
const sections = appSchema.definitions[ux_specification_types_1.DefinitionName.Sections];
|
|
440
526
|
for (const facetKey in facets) {
|
|
441
527
|
addSection(generateParameters, facets, facetKey, sections, appSchema, ux_specification_types_1.SectionType.Section, v4Page);
|
|
442
528
|
}
|
|
443
529
|
// Custom sections as part of sections
|
|
444
|
-
if (appSchema.definitions[
|
|
530
|
+
if (appSchema.definitions[ux_specification_types_1.DefinitionName.CustomSections]) {
|
|
445
531
|
sections.properties = {
|
|
446
532
|
...sections.properties,
|
|
447
|
-
...appSchema.definitions[
|
|
533
|
+
...appSchema.definitions[ux_specification_types_1.DefinitionName.CustomSections].properties
|
|
448
534
|
};
|
|
449
535
|
}
|
|
450
536
|
}
|
|
@@ -458,7 +544,7 @@ function addSections(generateParameters, appSchema, v4Page) {
|
|
|
458
544
|
function addHeaderSections(generateParameters, appSchema, entityType, v4Page) {
|
|
459
545
|
// Get facet annotations
|
|
460
546
|
const facets = common_1.getObjectPageHeaderFacets(entityType, generateParameters.serviceAVT, ux_specification_types_1.FioriElementsVersion.v4, generateParameters.logger);
|
|
461
|
-
const sections = appSchema.definitions[
|
|
547
|
+
const sections = appSchema.definitions[ux_specification_types_1.DefinitionName.HeaderSections];
|
|
462
548
|
sections.properties = {};
|
|
463
549
|
sections.additionalProperties = false;
|
|
464
550
|
if (!facets) {
|
|
@@ -468,11 +554,11 @@ function addHeaderSections(generateParameters, appSchema, entityType, v4Page) {
|
|
|
468
554
|
addSection(generateParameters, facets, facetKey, sections, appSchema, ux_specification_types_1.SectionType.HeaderSection, v4Page);
|
|
469
555
|
}
|
|
470
556
|
//delete generic definitions
|
|
471
|
-
delete appSchema.definitions[
|
|
472
|
-
delete appSchema.definitions[
|
|
473
|
-
delete appSchema.definitions[
|
|
474
|
-
delete appSchema.definitions[
|
|
475
|
-
delete appSchema.definitions[
|
|
557
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageHeaderSectionForm];
|
|
558
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageHeaderSectionChart];
|
|
559
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageHeaderSectionDataPoint];
|
|
560
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageHeaderSectionContact];
|
|
561
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageHeaderSectionAddress];
|
|
476
562
|
}
|
|
477
563
|
/**
|
|
478
564
|
* Adds the related facets keys 'enum' to the app schema
|
|
@@ -507,7 +593,7 @@ function addRelatedFacetKeysType(generateParameters, schema, entitySetName, page
|
|
|
507
593
|
});
|
|
508
594
|
}
|
|
509
595
|
// Update schema definition
|
|
510
|
-
common_1.addDefinitionForRelatedFacetKeys(schema, [
|
|
596
|
+
common_1.addDefinitionForRelatedFacetKeys(schema, [ux_specification_types_1.DefinitionName.ObjectPageCustomSectionFragment], facetSections, [
|
|
511
597
|
'ID',
|
|
512
598
|
'label',
|
|
513
599
|
'key'
|
|
@@ -527,7 +613,7 @@ function addHeader(generateParameters, appSchema, v4Page) {
|
|
|
527
613
|
// Add header actions
|
|
528
614
|
common_1.addHeaderActions(appSchema, entityType, generateParameters.serviceAVT, addHeaderActionCallBackV4);
|
|
529
615
|
// Add header sections
|
|
530
|
-
appSchema.definitions[
|
|
616
|
+
appSchema.definitions[ux_specification_types_1.DefinitionName.HeaderSections][ux_specification_types_1.SchemaTag.annotationPath] = `/${entityType.fullyQualifiedName}/@${"com.sap.vocabularies.UI.v1.HeaderFacets" /* HeaderFacets */}`;
|
|
531
617
|
addHeaderSections(generateParameters, appSchema, entityType, v4Page);
|
|
532
618
|
}
|
|
533
619
|
/**
|
|
@@ -543,7 +629,7 @@ function generateObjectPageSchemaV4(generateParameters, genericSchema, entityTyp
|
|
|
543
629
|
const appSchema = JSON.parse(JSON.stringify(genericSchema));
|
|
544
630
|
// Change reference to generated sections
|
|
545
631
|
appSchema.properties.sections = {
|
|
546
|
-
$ref: `${common_1.DEFINITION_LINK_PREFIX}${
|
|
632
|
+
$ref: `${common_1.DEFINITION_LINK_PREFIX}${ux_specification_types_1.DefinitionName.Sections}`
|
|
547
633
|
};
|
|
548
634
|
const entitySet = generateParameters.serviceAVT?.entitySets?.find((es) => es.entityType.name === entityTypeName);
|
|
549
635
|
if (!entitySet) {
|
|
@@ -551,7 +637,7 @@ function generateObjectPageSchemaV4(generateParameters, genericSchema, entityTyp
|
|
|
551
637
|
severity: "error" /* Error */,
|
|
552
638
|
message: i18next_1.default.t('NOENTITYSET4NAME', { entityType: entityTypeName }),
|
|
553
639
|
location: {
|
|
554
|
-
path:
|
|
640
|
+
path: ux_specification_types_1.METADATAPATH
|
|
555
641
|
}
|
|
556
642
|
});
|
|
557
643
|
}
|
|
@@ -562,19 +648,19 @@ function generateObjectPageSchemaV4(generateParameters, genericSchema, entityTyp
|
|
|
562
648
|
severity: "error" /* Error */,
|
|
563
649
|
message: i18next_1.default.t('NOROUTING'),
|
|
564
650
|
location: {
|
|
565
|
-
path:
|
|
651
|
+
path: ux_specification_types_1.MANIFESTPATH
|
|
566
652
|
}
|
|
567
653
|
});
|
|
568
654
|
return appSchema;
|
|
569
655
|
}
|
|
570
656
|
//initialize sections
|
|
571
|
-
const sections = (appSchema.definitions[
|
|
657
|
+
const sections = (appSchema.definitions[ux_specification_types_1.DefinitionName.Sections] = {
|
|
572
658
|
type: 'object',
|
|
573
659
|
properties: {},
|
|
574
660
|
additionalProperties: false,
|
|
575
|
-
description:
|
|
661
|
+
description: ux_specification_types_1.DefinitionName.Sections
|
|
576
662
|
});
|
|
577
|
-
sections[
|
|
663
|
+
sections[ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
578
664
|
if (entitySet) {
|
|
579
665
|
const pages = generateParameters.manifest[ux_specification_types_1.ManifestSection.ui5].routing
|
|
580
666
|
.targets;
|
|
@@ -583,7 +669,7 @@ function generateObjectPageSchemaV4(generateParameters, genericSchema, entityTyp
|
|
|
583
669
|
severity: "error" /* Error */,
|
|
584
670
|
message: i18next_1.default.t('NOPAGES', { appId: generateParameters.manifest['sap.app']['id'] }),
|
|
585
671
|
location: {
|
|
586
|
-
path:
|
|
672
|
+
path: ux_specification_types_1.MANIFESTPATH,
|
|
587
673
|
range: [ux_specification_types_1.ManifestSection.generic]
|
|
588
674
|
}
|
|
589
675
|
});
|
|
@@ -596,32 +682,32 @@ function generateObjectPageSchemaV4(generateParameters, genericSchema, entityTyp
|
|
|
596
682
|
// Add Header
|
|
597
683
|
addHeader(generateParameters, appSchema, v4Page);
|
|
598
684
|
// Add sections
|
|
599
|
-
sections[
|
|
600
|
-
sections[
|
|
685
|
+
sections[ux_specification_types_1.SchemaTag.isViewNode] = true;
|
|
686
|
+
sections[ux_specification_types_1.SchemaTag.annotationPath] = `/${entitySet.entityType.fullyQualifiedName}/@${"com.sap.vocabularies.UI.v1.Facets" /* Facets */}`;
|
|
601
687
|
addSections(generateParameters, appSchema, v4Page);
|
|
602
688
|
// Custom Section facets
|
|
603
689
|
addRelatedFacetKeysType(generateParameters, appSchema, entitySet.name, pages);
|
|
604
690
|
// Add Footer (actions only)
|
|
605
|
-
common_1.addFooterActions(appSchema, generateParameters);
|
|
691
|
+
common_1.addFooterActions(appSchema, generateParameters, ux_specification_types_1.FioriElementsVersion.v4, addFooterActionCallBackV4);
|
|
606
692
|
}
|
|
607
693
|
// Delete generic definitions from schema
|
|
608
|
-
delete appSchema.definitions[
|
|
609
|
-
delete appSchema.definitions[
|
|
610
|
-
delete appSchema.definitions[
|
|
611
|
-
delete appSchema.definitions[
|
|
612
|
-
delete appSchema.definitions[
|
|
613
|
-
delete appSchema.definitions[
|
|
614
|
-
delete appSchema.definitions[
|
|
615
|
-
delete appSchema.definitions[
|
|
616
|
-
delete appSchema.definitions[
|
|
617
|
-
delete appSchema.definitions[
|
|
618
|
-
delete appSchema.definitions[
|
|
619
|
-
delete appSchema.definitions[
|
|
620
|
-
delete appSchema.definitions[
|
|
621
|
-
delete appSchema.definitions[
|
|
622
|
-
delete appSchema.definitions[
|
|
623
|
-
delete appSchema.definitions[
|
|
624
|
-
delete appSchema.definitions[
|
|
694
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.CommonHeaderFacetSettings];
|
|
695
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.GenericColumnsOP];
|
|
696
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.GenericSections];
|
|
697
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageChart];
|
|
698
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageSectionAddress];
|
|
699
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageSectionChart];
|
|
700
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageSectionContact];
|
|
701
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageSectionDataPoint];
|
|
702
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageSectionForm];
|
|
703
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageSectionTableV4];
|
|
704
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageSectionPresentationVariant];
|
|
705
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageSubSections];
|
|
706
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageTable];
|
|
707
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageToolBar];
|
|
708
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageToolBarAction];
|
|
709
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.ObjectPageToolBarActions];
|
|
710
|
+
delete appSchema.definitions[ux_specification_types_1.DefinitionName.QuickVariantSelectionV4OP];
|
|
625
711
|
return appSchema;
|
|
626
712
|
}
|
|
627
713
|
exports.generateObjectPageSchemaV4 = generateObjectPageSchemaV4;
|