@sap/ux-specification 1.124.40 → 1.124.42
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/CHANGELOG.md +43 -9
- package/dist/documentation/runDocu-min.mjs +28 -0
- package/dist/documentation/{runDocu-min.js.map → runDocu-min.mjs.map} +2 -2
- package/dist/documentation/v2/v2-AnalyticalListPage.html +4 -4
- package/dist/documentation/v2/v2-ApplicationV2.html +4 -4
- package/dist/documentation/v2/v2-ListReport.html +4 -4
- package/dist/documentation/v2/v2-ListReportNew.html +4 -4
- package/dist/documentation/v2/v2-ObjectPage.html +4 -4
- package/dist/documentation/v2/v2-OverviewPage.html +4 -4
- package/dist/documentation/v4/v4-ApplicationV4.html +4 -4
- package/dist/documentation/v4/v4-BuildingBlocks.html +4 -4
- package/dist/documentation/v4/v4-FreestylePage.html +4 -4
- package/dist/documentation/v4/v4-ListReport.html +4 -4
- package/dist/documentation/v4/v4-ObjectPage.html +4 -4
- package/dist/index-min.mjs +1367 -0
- package/dist/index-min.mjs.map +7 -0
- package/dist/specification/package.json +22 -15
- package/dist/specification/src/i18n/i18n.js +35 -2
- package/dist/specification/src/i18n/i18n.js.map +1 -1
- package/dist/templates/action/manifest.action-menu.json +10 -0
- package/dist/templates/action/manifest.action.json +13 -0
- package/dist/templates/app/Component.js +13 -0
- package/dist/templates/app/Component.ts +11 -0
- package/dist/templates/building-block/action/View.xml +30 -0
- package/dist/templates/building-block/chart/View.xml +9 -0
- package/dist/templates/building-block/common/manifest.json +7 -0
- package/dist/templates/building-block/custom-column/View.xml +5 -0
- package/dist/templates/building-block/custom-filter-field/View.xml +12 -0
- package/dist/templates/building-block/custom-form-field/View.xml +12 -0
- package/dist/templates/building-block/field/View.xml +8 -0
- package/dist/templates/building-block/filter-bar/View.xml +10 -0
- package/dist/templates/building-block/form/View.xml +4 -0
- package/dist/templates/building-block/page/View.xml +5 -0
- package/dist/templates/building-block/rich-text-editor/View.xml +3 -0
- package/dist/templates/building-block/rich-text-editor-button-groups/View.xml +18 -0
- package/dist/templates/building-block/table/View.xml +19 -0
- package/dist/templates/column/1.84/manifest.json +28 -0
- package/dist/templates/column/1.85/manifest.json +31 -0
- package/dist/templates/column/1.86/manifest.json +43 -0
- package/dist/templates/common/EventHandler.js +25 -0
- package/dist/templates/common/EventHandler.ts +28 -0
- package/dist/templates/common/Fragment.xml +3 -0
- package/dist/templates/common/FragmentWithForm.xml +7 -0
- package/dist/templates/common/FragmentWithVBox.xml +5 -0
- package/dist/templates/common/sap.fe.d.ts +43 -0
- package/dist/templates/controller-extension/Controller.js +18 -0
- package/dist/templates/controller-extension/Controller.ts +20 -0
- package/dist/templates/controller-extension/ControllerExtension.d.ts +11 -0
- package/dist/templates/controller-extension/manifest.json +14 -0
- package/dist/templates/field/manifest.json +32 -0
- package/dist/templates/filter/Controller.js +21 -0
- package/dist/templates/filter/Controller.ts +24 -0
- package/dist/templates/filter/fragment.xml +15 -0
- package/dist/templates/filter/manifest.json +12 -0
- package/dist/templates/header-section/1.85/manifest.json +43 -0
- package/dist/templates/header-section/1.86/manifest.json +45 -0
- package/dist/templates/page/custom/1.84/ext/Controller.js +45 -0
- package/dist/templates/page/custom/1.84/ext/Controller.ts +42 -0
- package/dist/templates/page/custom/1.84/ext/View.xml +6 -0
- package/dist/templates/page/custom/1.84/i18n/i18n.properties +2 -0
- package/dist/templates/page/custom/1.84/manifest.json +32 -0
- package/dist/templates/page/custom/1.94/ext/Controller.js +45 -0
- package/dist/templates/page/custom/1.94/ext/Controller.ts +42 -0
- package/dist/templates/page/custom/1.94/ext/View.xml +6 -0
- package/dist/templates/page/custom/1.94/i18n/i18n.properties +2 -0
- package/dist/templates/page/custom/1.94/manifest.json +33 -0
- package/dist/templates/page/custom/i18n/i18n.properties +2 -0
- package/dist/templates/page/list/manifest.json +20 -0
- package/dist/templates/page/object/manifest.json +33 -0
- package/dist/templates/section/1.85/manifest.json +33 -0
- package/dist/templates/section/1.86/manifest.json +32 -0
- package/dist/templates/subsection/1.85/manifest.json +37 -0
- package/dist/templates/subsection/1.86/manifest.json +36 -0
- package/dist/templates/view/ext/CustomViewWithTable.xml +3 -0
- package/dist/templates/view/manifest.json +41 -0
- package/package.json +22 -15
- package/dist/documentation/runDocu-min.js +0 -28
- package/dist/index-min.js +0 -649
- package/dist/index-min.js.map +0 -7
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sap/ux-specification",
|
|
3
|
-
"version": "1.124.
|
|
3
|
+
"version": "1.124.42",
|
|
4
4
|
"displayName": "SAP Fiori tools - Specification",
|
|
5
5
|
"description": "SAP Fiori tools - Specification",
|
|
6
6
|
"files": [
|
|
@@ -8,10 +8,17 @@
|
|
|
8
8
|
"CHANGELOG.md",
|
|
9
9
|
"!dist/scripts"
|
|
10
10
|
],
|
|
11
|
-
"main": "dist/index-min.
|
|
11
|
+
"main": "dist/index-min.mjs",
|
|
12
|
+
"exports": {
|
|
13
|
+
".": {
|
|
14
|
+
"types": "./dist/index.d.ts",
|
|
15
|
+
"import": "./dist/index-min.mjs",
|
|
16
|
+
"default": "./dist/index-min.mjs"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
12
19
|
"engines": {
|
|
13
|
-
"node": ">=
|
|
14
|
-
"yarn": ">=1.22.
|
|
20
|
+
"node": ">=22.13.0 <23.0.0 || >=24.0.0 <25.0.0 || >=26.0.0",
|
|
21
|
+
"yarn": ">=1.22.22 < 2"
|
|
15
22
|
},
|
|
16
23
|
"scripts": {
|
|
17
24
|
"clean:before": "rimraf ./dist ./types ./schemas",
|
|
@@ -41,23 +48,22 @@
|
|
|
41
48
|
"lint:report": "eslint . -f multiple",
|
|
42
49
|
"lint:report:jslint": "eslint . -o reports/lint/eslint.jslint.xml -f jslint-xml",
|
|
43
50
|
"macros": "ts-node ./scripts/macros/index.ts",
|
|
44
|
-
"
|
|
45
|
-
"test
|
|
51
|
+
"macros:update": "npm run macros -- --update",
|
|
52
|
+
"test": "NODE_OPTIONS=--experimental-vm-modules jest && node ../../scripts/scov.js reports/test/unit/coverage/lcov.info",
|
|
53
|
+
"test:ci": "NODE_OPTIONS=--experimental-vm-modules node --max-old-space-size=4096 ./node_modules/.bin/jest --ci --forceExit --detectOpenHandles && node ../../scripts/scov.js reports/test/unit/coverage/lcov.info",
|
|
46
54
|
"update-snapshots": "jest --updateSnapshot",
|
|
47
55
|
"watch": "npm-run-all -l -s clean:before -p compile create-json-schemas macros copy-templates -p copy-json-schemas -s bundle:watch",
|
|
48
56
|
"watch:doc": "npm-run-all -l -s clean:doc -s compile -s htmlV2 htmlV4 -s bundle:watch"
|
|
49
57
|
},
|
|
50
58
|
"publisher": "SAPSE",
|
|
51
59
|
"license": "SEE LICENSE IN LICENSE",
|
|
52
|
-
"dependencies": {
|
|
53
|
-
"@sap-ux/fe-fpm-writer": "0.43.28",
|
|
54
|
-
"@sap-ux/vocabularies-types": "0.15.0"
|
|
55
|
-
},
|
|
56
60
|
"devDependencies": {
|
|
57
61
|
"@sap-ux/annotation-converter": "0.10.21",
|
|
58
62
|
"@sap-ux/edmx-parser": "0.10.0",
|
|
59
|
-
"@sap-ux/
|
|
60
|
-
"@sap/
|
|
63
|
+
"@sap-ux/fe-fpm-writer": "1.0.8",
|
|
64
|
+
"@sap-ux/project-access": "1.38.1",
|
|
65
|
+
"@sap-ux/vocabularies-types": "0.15.0",
|
|
66
|
+
"@sap/ux-specification-types": "1.124.42",
|
|
61
67
|
"@sapui5/types": "latest-1.124",
|
|
62
68
|
"@types/d3": "7.4.3",
|
|
63
69
|
"@types/jquery": "3.5.34",
|
|
@@ -67,14 +73,15 @@
|
|
|
67
73
|
"@ui5/flexibility-utils": "0.1.3",
|
|
68
74
|
"@xml-tools/ast": "5.0.5",
|
|
69
75
|
"@xml-tools/parser": "1.0.11",
|
|
70
|
-
"axios": "1.
|
|
76
|
+
"axios": "1.18.0",
|
|
71
77
|
"cpy-cli": "7.0.0",
|
|
78
|
+
"cross-env": "10.1.0",
|
|
72
79
|
"d3": "7.9.0",
|
|
73
80
|
"deepmerge": "4.3.1",
|
|
74
81
|
"ejs": "3.1.10",
|
|
75
82
|
"eslint-formatter-checkstyle": "9.0.1",
|
|
76
83
|
"excel4node": "1.8.2",
|
|
77
|
-
"i18next": "25.
|
|
84
|
+
"i18next": "25.10.10",
|
|
78
85
|
"jquery": "3.7.1",
|
|
79
86
|
"jsdom": "25.0.1",
|
|
80
87
|
"jsonpath-plus": "10.4.0",
|
|
@@ -82,7 +89,7 @@
|
|
|
82
89
|
"mem-fs-editor": "9.7.0",
|
|
83
90
|
"path": "0.12.7",
|
|
84
91
|
"reflect-metadata": "0.2.2",
|
|
85
|
-
"semver": "7.8.
|
|
92
|
+
"semver": "7.8.4",
|
|
86
93
|
"typescript-json-schema": "0.67.1",
|
|
87
94
|
"xml-js": "1.6.11"
|
|
88
95
|
},
|
|
@@ -1,11 +1,44 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
2
35
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
37
|
};
|
|
5
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
39
|
exports.initI18n = initI18n;
|
|
7
40
|
const i18next_1 = __importDefault(require("i18next"));
|
|
8
|
-
const
|
|
41
|
+
const i18nEn = __importStar(require("@sap/ux-specification-types"));
|
|
9
42
|
const i18n_1 = require("../sync/i18n");
|
|
10
43
|
/**
|
|
11
44
|
* Initializes i18next with the given language.
|
|
@@ -17,7 +50,7 @@ function initI18n(language = 'en') {
|
|
|
17
50
|
i18next_1.default.init({
|
|
18
51
|
resources: {
|
|
19
52
|
en: {
|
|
20
|
-
translation:
|
|
53
|
+
translation: i18nEn
|
|
21
54
|
}
|
|
22
55
|
},
|
|
23
56
|
lng: language,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"i18n.js","sourceRoot":"","sources":["../../../../src/i18n/i18n.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"i18n.js","sourceRoot":"","sources":["../../../../src/i18n/i18n.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AASA,4BAgBC;AAzBD,sDAA8B;AAC9B,oEAAsD;AACtD,uCAAwD;AAExD;;;;GAIG;AACH,SAAgB,QAAQ,CAAC,QAAQ,GAAG,IAAI;IACpC,sCAAsC;IACtC,iBAAO,CAAC,IAAI,CAAC;QACT,SAAS,EAAE;YACP,EAAE,EAAE;gBACA,WAAW,EAAE,MAAM;aACtB;SACJ;QACD,GAAG,EAAE,QAAQ;QACb,WAAW,EAAE,IAAI;QACjB,UAAU,EAAE,MAAM;QAClB,iBAAiB,EAAE,KAAK;KAC3B,CAAC,CAAC;IAEH,oCAAoC;IACpC,IAAA,eAAY,EAAC,iBAAO,CAAC,CAAC;AAC1B,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"<%- name %>": {
|
|
3
|
+
"text": "<%- settings.text %>",
|
|
4
|
+
"menu": <%- JSON.stringify(settings.actions) %><%if (settings.position) {%>,
|
|
5
|
+
"position": {
|
|
6
|
+
"placement": "<%- settings.position.placement %>"<%if (settings.position.anchor !== undefined) {%>,
|
|
7
|
+
"anchor": "<%- settings.position.anchor %>"<% } %>
|
|
8
|
+
}<% } %>
|
|
9
|
+
}
|
|
10
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"<%- name %>": {
|
|
3
|
+
"press": "<%- typeof eventHandler !== 'undefined' ? eventHandler : '' %>",
|
|
4
|
+
"visible": <%- settings.visible -%>,
|
|
5
|
+
"enabled": <%- settings.enabled -%><%if (settings.requiresSelection !== undefined) {%>,
|
|
6
|
+
"requiresSelection": <%- settings.requiresSelection -%><% } %>,
|
|
7
|
+
"text": "<%- settings.text %>"<%if (settings.position) {%>,
|
|
8
|
+
"position": {
|
|
9
|
+
"placement": "<%- settings.position.placement %>"<%if (settings.position.anchor !== undefined) {%>,
|
|
10
|
+
"anchor": "<%- settings.position.anchor %>"<% } %>
|
|
11
|
+
}<% } %>
|
|
12
|
+
}
|
|
13
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
<%_ if (!config?.hasAggregation) { _%>
|
|
2
|
+
<<%- macrosNamespace %>:actions>
|
|
3
|
+
<%_ } _%>
|
|
4
|
+
<<%- config?.aggregationNamespace %>:Action
|
|
5
|
+
<%_ if (data.embeddedAction?.eventHandler?.fileName) { _%>
|
|
6
|
+
core:require="{ handler: '<%- data.embeddedAction.eventHandler.fileName %>' }"
|
|
7
|
+
<%_ } _%>
|
|
8
|
+
<%_ if (data.id) { _%>
|
|
9
|
+
id="<%- data.id %>"
|
|
10
|
+
<%_ } _%>
|
|
11
|
+
<%_ if (data.actionKey) { _%>
|
|
12
|
+
key="<%- data.actionKey %>"
|
|
13
|
+
<%_ } _%>
|
|
14
|
+
text="<%- data.text %>"
|
|
15
|
+
<%_ if (data.embeddedAction?.eventHandler?.fnName) { _%>
|
|
16
|
+
press="<%- data.embeddedAction.eventHandler.fnName %>"
|
|
17
|
+
<%_ } _%>
|
|
18
|
+
<%_ if (data.anchor) { _%>
|
|
19
|
+
anchor="<%- data.anchor %>"
|
|
20
|
+
<%_ } _%>
|
|
21
|
+
<%_ if (data.placement) { _%>
|
|
22
|
+
placement="<%- data.placement %>"
|
|
23
|
+
<%_ } _%>
|
|
24
|
+
<%_ if (data.requiresSelection !== undefined) { _%>
|
|
25
|
+
requiresSelection="<%- data.requiresSelection %>"
|
|
26
|
+
<%_ } _%>
|
|
27
|
+
/>
|
|
28
|
+
<%_ if (!config?.hasAggregation) { _%>
|
|
29
|
+
</<%- macrosNamespace %>:actions>
|
|
30
|
+
<%_ } _%>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
<<%- macrosNamespace %>:Chart
|
|
2
|
+
id="<%- data.id %>"<% if (data.metaPath) { %>
|
|
3
|
+
metaPath="<%- data.metaPath %>"<% } %><% if (data.contextPath) { %>
|
|
4
|
+
contextPath="<%- data.contextPath %>"<% } %><% if (data.filterBar) { %>
|
|
5
|
+
filterBar="<%- data.filterBar %>"<% } %><% if (data.personalization) { %>
|
|
6
|
+
personalization="<%- data.personalization %>"<% } %><% if (data.selectionMode) { %>
|
|
7
|
+
selectionMode="<%- data.selectionMode %>"<% } %><% if (data.selectionChange) { %>
|
|
8
|
+
selectionChange="<%- data.selectionChange %>"<% } %>
|
|
9
|
+
/>
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<% if (!config?.hasAggregation) { %><<%- macrosNamespace %>:columns>
|
|
2
|
+
<% } %><<%- config?.aggregationNamespace %>:Column <% if (ids.column) { %>id="<%- ids.column %>"<% } %> header="<%- data.title %>" importance="High" <% if (data.width) { %>width="<%- data.width %>"<% } %> <% if (data.position.anchor) { %>anchor="<%- data.position.anchor %>"<% } %> <% if (data.position.placement) { %>placement="<%- data.position.placement %>"<% } %> key="<%- data.columnKey || 'myColumnKey' %>">
|
|
3
|
+
<core:Fragment fragmentName="<%- data.embededFragment.ns %>.<%- data.embededFragment.name %>" type="XML" />
|
|
4
|
+
</<%- config?.aggregationNamespace %>:Column>
|
|
5
|
+
<% if (!config?.hasAggregation) { %></<%- macrosNamespace %>:columns><% } %>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<% if (!config?.hasAggregation) { %><<%- macrosNamespace %>:filterFields><% } %>
|
|
2
|
+
<<%- config?.aggregationNamespace %>:FilterField
|
|
3
|
+
key="<%- data.filterFieldKey || 'myFilterFieldKey'%>"
|
|
4
|
+
label="<%- data.label %>"
|
|
5
|
+
<% if (data.id) { %> id="<%- data.id %>"<% } %>
|
|
6
|
+
<% if (data.position.anchor) { %> anchor="<%- data.position.anchor %>"<% } %>
|
|
7
|
+
<% if (data.position.placement) { %> placement="<%- data.position.placement %>"<% } %>
|
|
8
|
+
<% if (data.required) { %> required="<%- data.required %>"<% } %>
|
|
9
|
+
<% if (data.property) { %> property="<%- data.property %>"<% } %>>
|
|
10
|
+
<core:Fragment fragmentName="<%- data.embededFragment.ns %>.<%- data.embededFragment.name %>" type="XML" />
|
|
11
|
+
</<%- config?.aggregationNamespace %>:FilterField>
|
|
12
|
+
<% if (!config?.hasAggregation) { %></<%- macrosNamespace %>:filterFields><% } %>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<<%- config?.aggregationNamespace %>:FormElement
|
|
2
|
+
<% if (data.formElementKey) { %> key="<%- data.formElementKey %>"<% } %>
|
|
3
|
+
label="<%- data.label %>"
|
|
4
|
+
<% if (data.id) { %> id="<%- data.id %>"<% } %>
|
|
5
|
+
<% if (data.metaPath) { %> metaPath="<%- data.metaPath %>"<% } %>
|
|
6
|
+
<% if (data.contextPath) { %> contextPath="<%- data.contextPath %>"<% } %>
|
|
7
|
+
<% if (data.position?.anchor) { %> anchor="<%- data.position.anchor %>"<% } %>
|
|
8
|
+
<% if (data.position?.placement) { %> placement="<%- data.position.placement %>"<% } %>>
|
|
9
|
+
<<%- config?.aggregationNamespace %>:fields>
|
|
10
|
+
<core:Fragment fragmentName="<%- data.embededFragment.ns %>.<%- data.embededFragment.name %>" type="XML" />
|
|
11
|
+
</<%- config?.aggregationNamespace %>:fields>
|
|
12
|
+
</<%- config?.aggregationNamespace %>:FormElement>
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
<<%- macrosNamespace %>:Field
|
|
2
|
+
id="<%- data.id %>"<% if (data.metaPath) { %>
|
|
3
|
+
metaPath="<%- data.metaPath %>"<% } %><% if (data.contextPath) { %>
|
|
4
|
+
contextPath="<%- data.contextPath %>"<% } %><% if (data.formatOptions) { %>
|
|
5
|
+
formatOptions="<%- data.formatOptions %>"<% } %><% if (data.readOnly) { %>
|
|
6
|
+
readOnly="<%- data.readOnly %>"<% } %><% if (data.semanticObject) { %>
|
|
7
|
+
semanticObject="<%- data.semanticObject %>"<% } %>
|
|
8
|
+
/>
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
<<%- macrosNamespace %>:FilterBar
|
|
2
|
+
id="<%- data.id %>"<% if (data.metaPath) { %>
|
|
3
|
+
metaPath="<%- data.metaPath %>"<% } %><% if (data.contextPath) { %>
|
|
4
|
+
contextPath="<%- data.contextPath %>"<% } %><% if (data.search) { %>
|
|
5
|
+
search="<%- data.search %>"<% } %><% if (data.filterChanged) { %>
|
|
6
|
+
filterChanged="<%- data.filterChanged %>"<% } %><% if (data.liveMode !== undefined) { %>
|
|
7
|
+
liveMode="<%- data.liveMode %>"<% } %><% if (data.showClearButton !== undefined) { %>
|
|
8
|
+
showClearButton="<%- data.showClearButton %>"<% } %><% if (data.showMessages !== undefined) { %>
|
|
9
|
+
showMessages="<%- data.showMessages %>"<% } %>
|
|
10
|
+
/>
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<<%- config.aggregationNamespace %>:buttonGroups>
|
|
2
|
+
<% (data.buttonGroups || []).forEach(function(buttonGroup, idKey) { %>
|
|
3
|
+
<richtexteditor:ButtonGroup
|
|
4
|
+
id="<%- buttonGroup.id || ids[idKey] %>"
|
|
5
|
+
name="<%- buttonGroup.name %>"
|
|
6
|
+
visible="<%- buttonGroup.visible !== undefined ? buttonGroup.visible : true %>"
|
|
7
|
+
buttons="<%- buttonGroup.buttons %>"<%
|
|
8
|
+
if (buttonGroup.priority !== undefined) { %>
|
|
9
|
+
priority="<%- buttonGroup.priority %>"<%
|
|
10
|
+
} %><%
|
|
11
|
+
if (buttonGroup.customToolbarPriority !== undefined) { %>
|
|
12
|
+
customToolbarPriority="<%- buttonGroup.customToolbarPriority %>"<%
|
|
13
|
+
} %><%
|
|
14
|
+
if (buttonGroup.row !== undefined) { %>
|
|
15
|
+
row="<%- buttonGroup.row %>"<%
|
|
16
|
+
} %>/>
|
|
17
|
+
<% }); %>
|
|
18
|
+
</<%- config.aggregationNamespace %>:buttonGroups>
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<<%- macrosNamespace %>:Table
|
|
2
|
+
id="<%- data.id %>"<% if (data.metaPath) { %>
|
|
3
|
+
metaPath="<%- data.metaPath %>"<% } %><% if (data.contextPath) { %>
|
|
4
|
+
contextPath="<%- data.contextPath %>"<% } %><% if (data.busy) { %>
|
|
5
|
+
busy="<%- data.busy %>"<% } %><% if (data.enableAutoColumnWidth) { %>
|
|
6
|
+
enableAutoColumnWidth="<%- data.enableAutoColumnWidth %>"<% } %><% if (data.enableExport) { %>
|
|
7
|
+
enableExport="<%- data.enableExport %>"<% } %><% if (data.enableFullScreen) { %>
|
|
8
|
+
enableFullScreen="<%- data.enableFullScreen %>"<% } %><% if (data.enablePaste) { %>
|
|
9
|
+
enablePaste="<%- data.enablePaste %>"<% } %><% if (data.filterBar) { %>
|
|
10
|
+
filterBar="<%- data.filterBar %>"<% } %><% if (data.header) { %>
|
|
11
|
+
header="<%- data.header %>"<% } %><% if (data.headerVisible) { %>
|
|
12
|
+
headerVisible="<%- data.headerVisible %>"<% } %><% if (data.isSearchable) { %>
|
|
13
|
+
isSearchable="<%- data.isSearchable %>"<% } %><% if (data.personalization) { %>
|
|
14
|
+
personalization="<%- data.personalization %>"<% } %><% if (data.readOnly) { %>
|
|
15
|
+
readOnly="<%- data.readOnly %>"<% } %><% if (data.selectionMode) { %>
|
|
16
|
+
selectionMode="<%- data.selectionMode %>"<% } %><% if (data.type) { %>
|
|
17
|
+
type="<%- data.type %>"<% } %><% if (data.variantManagement) { %>
|
|
18
|
+
variantManagement="<%- data.variantManagement %>"<% } %>
|
|
19
|
+
/>
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"sap.ui5": {
|
|
3
|
+
"routing": {
|
|
4
|
+
"targets": {
|
|
5
|
+
"<%- target %>": {
|
|
6
|
+
"options": {
|
|
7
|
+
"settings": {
|
|
8
|
+
"controlConfiguration": {
|
|
9
|
+
"<%- targetEntity %>": {
|
|
10
|
+
"columns": {
|
|
11
|
+
"<%- name %>": {
|
|
12
|
+
"header": "<%- header %>",
|
|
13
|
+
<% if (locals.width) { %>
|
|
14
|
+
"width": "<%- width %>",
|
|
15
|
+
<% } %>
|
|
16
|
+
"position": <%- JSON.stringify(position) %>,
|
|
17
|
+
"template": "<%- ns %>.<%- typeof fragmentFile !== 'undefined' ? fragmentFile : name %>"
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"sap.ui5": {
|
|
3
|
+
"routing": {
|
|
4
|
+
"targets": {
|
|
5
|
+
"<%- target %>": {
|
|
6
|
+
"options": {
|
|
7
|
+
"settings": {
|
|
8
|
+
"controlConfiguration": {
|
|
9
|
+
"<%- targetEntity %>": {
|
|
10
|
+
"columns": {
|
|
11
|
+
"<%- name %>": {
|
|
12
|
+
"header": "<%- header %>",
|
|
13
|
+
<% if (locals.width) { %>
|
|
14
|
+
"width": "<%- width %>",
|
|
15
|
+
<% } %>
|
|
16
|
+
"position": <%- JSON.stringify(position) %>,
|
|
17
|
+
"template": "<%- ns %>.<%- typeof fragmentFile !== 'undefined' ? fragmentFile : name %>"
|
|
18
|
+
<% if (locals.availability) { %>
|
|
19
|
+
, "availability": "<%- availability %>"
|
|
20
|
+
<% } %>
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
{
|
|
2
|
+
"sap.ui5": {
|
|
3
|
+
"routing": {
|
|
4
|
+
"targets": {
|
|
5
|
+
"<%- target %>": {
|
|
6
|
+
"options": {
|
|
7
|
+
"settings": {
|
|
8
|
+
"controlConfiguration": {
|
|
9
|
+
"<%- targetEntity %>": {
|
|
10
|
+
"columns": {
|
|
11
|
+
"<%- name %>": {
|
|
12
|
+
"header": "<%- header %>",
|
|
13
|
+
<% if (locals.width) { %> "width": "<%- width %>", <%
|
|
14
|
+
} %>
|
|
15
|
+
"position": <%- JSON.stringify(position) %>,
|
|
16
|
+
<% if (locals.horizontalAlign) { %> "horizontalAlign": "<%- horizontalAlign %>", <%
|
|
17
|
+
} %>
|
|
18
|
+
"template": "<%- ns %>.<%- typeof fragmentFile !== 'undefined' ? fragmentFile : name %>"
|
|
19
|
+
<% if (locals.availability) { %> , "availability": "<%- availability %>" <%
|
|
20
|
+
} %>
|
|
21
|
+
<% if (locals.properties) { %> , "properties": [
|
|
22
|
+
<% for (var i =0; i < properties.length; i++) { %>
|
|
23
|
+
"<%- properties[i] %>"
|
|
24
|
+
<% if (i < properties.length - 1) { %>
|
|
25
|
+
,
|
|
26
|
+
<%
|
|
27
|
+
} %>
|
|
28
|
+
<%
|
|
29
|
+
} %>
|
|
30
|
+
]
|
|
31
|
+
<%
|
|
32
|
+
} %>
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
sap.ui.define([
|
|
2
|
+
"sap/m/MessageToast"
|
|
3
|
+
], function(MessageToast) {
|
|
4
|
+
'use strict';
|
|
5
|
+
|
|
6
|
+
return {
|
|
7
|
+
<% if (typeof parameters !== "undefined" && parameters.length) { -%>
|
|
8
|
+
/**
|
|
9
|
+
* Generated event handler.
|
|
10
|
+
*
|
|
11
|
+
<% parameters.forEach(function(param) { -%>
|
|
12
|
+
* @param <%- param.jsName %> <%- param.description %>
|
|
13
|
+
<% }) -%>
|
|
14
|
+
*/
|
|
15
|
+
<% } -%>
|
|
16
|
+
<%- eventHandlerFnName %>: function(<%=
|
|
17
|
+
(typeof parameters !== "undefined" ? parameters : [])
|
|
18
|
+
.map(function(param) {
|
|
19
|
+
return param.jsName;
|
|
20
|
+
}).join(", ")
|
|
21
|
+
-%>) {
|
|
22
|
+
MessageToast.show("Custom handler invoked.");
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
});
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import ExtensionAPI from 'sap/fe/core/ExtensionAPI';
|
|
2
|
+
<%
|
|
3
|
+
const importedTypes = new Set();
|
|
4
|
+
parameters.forEach(param => {
|
|
5
|
+
if (param.importType && !importedTypes.has(param.importType)) {
|
|
6
|
+
importedTypes.add(param.importType);
|
|
7
|
+
-%>
|
|
8
|
+
import <%- param.importType %> from '<%- param.importSource %>';
|
|
9
|
+
<%
|
|
10
|
+
}
|
|
11
|
+
}); -%>
|
|
12
|
+
import MessageToast from 'sap/m/MessageToast';
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Generated event handler.
|
|
16
|
+
*
|
|
17
|
+
* @param this reference to the 'this' that the event handler is bound to.
|
|
18
|
+
<% parameters.forEach(function(param) { -%>
|
|
19
|
+
* @param <%- param.name %> <%- param.description %>
|
|
20
|
+
<% }) -%>
|
|
21
|
+
*/
|
|
22
|
+
export function <%- eventHandlerFnName %>(this: ExtensionAPI, <%=
|
|
23
|
+
parameters.map(function(param) {
|
|
24
|
+
return param.name + ": " + (param.paramType ?? param.importType);
|
|
25
|
+
}).join(", ")
|
|
26
|
+
%>) {
|
|
27
|
+
MessageToast.show("Custom handler invoked.");
|
|
28
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
<core:FragmentDefinition xmlns:core="sap.ui.core" xmlns="sap.m" xmlns:f="sap.ui.layout.form"<%- typeof dependencies !== 'undefined' ? ` ${dependencies}` : '' %>>
|
|
2
|
+
<f:FormElement id="<%- ids.formElement %>"<%- typeof requireAttribute !== 'undefined' ? ` ${requireAttribute}` : '' %>>
|
|
3
|
+
<f:fields>
|
|
4
|
+
<%- content %>
|
|
5
|
+
</f:fields>
|
|
6
|
+
</f:FormElement>
|
|
7
|
+
</core:FragmentDefinition>
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<core:FragmentDefinition xmlns:core="sap.ui.core" xmlns="sap.m"<%- typeof dependencies !== 'undefined' ? ` ${dependencies}` : '' %>>
|
|
2
|
+
<VBox id="<%- ids.vbox %>"<%- typeof requireAttribute !== 'undefined' ? ` ${requireAttribute}` : '' %>>
|
|
3
|
+
<%- content %>
|
|
4
|
+
</VBox>
|
|
5
|
+
</core:FragmentDefinition>
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import ExtensionAPI from 'sap/fe/core/ExtensionAPI';
|
|
2
|
+
import Routing from 'sap/fe/core/controllerextensions/Routing';
|
|
3
|
+
import EditFlow from 'sap/fe/core/controllerextensions/EditFlow';
|
|
4
|
+
import IntentBasedNavigation from 'sap/fe/core/controllerextensions/IntentBasedNavigation';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Missing public properties (https://ui5.sap.com/#/api/sap.fe.core.ExtensionAPI)
|
|
8
|
+
*/
|
|
9
|
+
interface ExtensionAPIProperties {
|
|
10
|
+
routing: Routing;
|
|
11
|
+
editFlow: EditFlow;
|
|
12
|
+
intentBasedNavigation: IntentBasedNavigation;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Add missing public properties
|
|
17
|
+
*/
|
|
18
|
+
declare module 'sap/fe/core/ExtensionAPI' {
|
|
19
|
+
export default interface ExtensionAPI extends ExtensionAPIProperties {}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Add missing public properties
|
|
24
|
+
*/
|
|
25
|
+
declare module 'sap/fe/templates/ObjectPage/ExtensionAPI' {
|
|
26
|
+
export default interface ExtensionAPI extends ExtensionAPIProperties {}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Add missing public properties
|
|
31
|
+
*/
|
|
32
|
+
declare module 'sap/fe/templates/ListReport/ExtensionAPI' {
|
|
33
|
+
export default interface ExtensionAPI extends ExtensionAPIProperties {}
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Enhancing the PageController type to simplify the work with the extension API
|
|
38
|
+
*/
|
|
39
|
+
declare module 'sap/fe/core/PageController' {
|
|
40
|
+
export default interface PageController {
|
|
41
|
+
getExtensionAPI() : ExtensionAPI;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
sap.ui.define(['sap/ui/core/mvc/ControllerExtension'], function (ControllerExtension) {
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
return ControllerExtension.extend('<%- ns %>.<%- name %>', {
|
|
5
|
+
// this section allows to extend lifecycle hooks or hooks provided by Fiori elements
|
|
6
|
+
override: {
|
|
7
|
+
/**
|
|
8
|
+
* Called when a controller is instantiated and its View controls (if available) are already created.
|
|
9
|
+
* Can be used to modify the View before it is displayed, to bind event handlers and do other one-time initialization.
|
|
10
|
+
* @memberOf <%- ns %>.<%- name %>
|
|
11
|
+
*/
|
|
12
|
+
onInit: function () {
|
|
13
|
+
// you can access the Fiori elements extensionAPI via this.base.getExtensionAPI
|
|
14
|
+
var oModel = this.base.getExtensionAPI().getModel();
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
});
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import ControllerExtension from 'sap/ui/core/mvc/ControllerExtension';
|
|
2
|
+
import ExtensionAPI from 'sap/fe/<%- typeof extension === "object" ? `templates/${extension.pageType}` : "core" -%>/ExtensionAPI';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* @namespace <%- ns %>
|
|
6
|
+
* @controller
|
|
7
|
+
*/
|
|
8
|
+
export default class <%- name %> extends ControllerExtension<ExtensionAPI> {
|
|
9
|
+
static overrides = {
|
|
10
|
+
/**
|
|
11
|
+
* Called when a controller is instantiated and its View controls (if available) are already created.
|
|
12
|
+
* Can be used to modify the View before it is displayed, to bind event handlers and do other one-time initialization.
|
|
13
|
+
* @memberOf <%- ns %>.<%- name %>
|
|
14
|
+
*/
|
|
15
|
+
onInit(this: <%- name %>) {
|
|
16
|
+
// you can access the Fiori elements extensionAPI via this.base.getExtensionAPI
|
|
17
|
+
const model = this.base.getExtensionAPI().getModel();
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
}
|