@sap-ux/fe-fpm-writer 0.24.13 → 0.24.14
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/action/index.js +12 -9
- package/package.json +1 -1
package/dist/action/index.js
CHANGED
|
@@ -37,7 +37,6 @@ function enhanceConfig(data, manifestPath, manifest) {
|
|
|
37
37
|
*/
|
|
38
38
|
function enhanceManifestAndGetActionsElementReference(manifest, target) {
|
|
39
39
|
const page = manifest['sap.ui5'].routing.targets[target.page];
|
|
40
|
-
const SECTIONS = 'sections';
|
|
41
40
|
page.options = page.options || {};
|
|
42
41
|
page.options.settings = page.options.settings || {};
|
|
43
42
|
if (target.control === types_1.TargetControl.header || target.control === types_1.TargetControl.footer) {
|
|
@@ -48,16 +47,20 @@ function enhanceManifestAndGetActionsElementReference(manifest, target) {
|
|
|
48
47
|
return page.options.settings.content[target.control].actions;
|
|
49
48
|
}
|
|
50
49
|
else if (target.control === types_1.TargetControl.body && target.customSectionKey) {
|
|
51
|
-
// custom section actions
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
page.options.settings
|
|
55
|
-
|
|
56
|
-
page.options.settings[target.control][
|
|
57
|
-
|
|
58
|
-
|
|
50
|
+
// condition for custom section actions
|
|
51
|
+
// Custom actions for custom sections are defined similarly like for header/footer under content property
|
|
52
|
+
// In: 'options/settings/content/body/sections/<customSection>/actions'
|
|
53
|
+
page.options.settings.content = page.options.settings.content || {};
|
|
54
|
+
page.options.settings.content[target.control] = page.options.settings.content[target.control] || {};
|
|
55
|
+
page.options.settings.content[target.control].sections = page.options.settings.content[target.control].sections || {};
|
|
56
|
+
page.options.settings.content[target.control].sections[target.customSectionKey] =
|
|
57
|
+
page.options.settings.content[target.control].sections[target.customSectionKey] || {};
|
|
58
|
+
page.options.settings.content[target.control].sections[target.customSectionKey].actions =
|
|
59
|
+
page.options.settings.content[target.control].sections[target.customSectionKey].actions || {};
|
|
60
|
+
return page.options.settings.content[target.control].sections[target.customSectionKey].actions;
|
|
59
61
|
}
|
|
60
62
|
else {
|
|
63
|
+
// Custom actions for other elements are defined in: 'options/settings/controlConfiguration/<element>/actions'
|
|
61
64
|
const controlPrefix = target.navProperty ? target.navProperty + '/' : '';
|
|
62
65
|
const controlSuffix = target.qualifier ? '#' + target.qualifier : '';
|
|
63
66
|
const controlId = `${controlPrefix}${target.control}${controlSuffix}`;
|
package/package.json
CHANGED