@sap-ux/fiori-app-sub-generator 0.6.24 → 0.7.1
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.
|
@@ -150,11 +150,14 @@ class FioriAppGenerator extends yeoman_generator_1.default {
|
|
|
150
150
|
}
|
|
151
151
|
else if (this.state.service.edmx) {
|
|
152
152
|
// Fiori Elements templates require entity and related settings
|
|
153
|
-
const
|
|
153
|
+
const templateType = (0, transforms_1.getTemplateType)(this.state.floorplan);
|
|
154
|
+
const promptOptions = {
|
|
154
155
|
defaultMainEntityName: generatorOptions.preselectedEntityName,
|
|
155
156
|
useAutoComplete: (0, fiori_generator_shared_1.getHostEnvironment)() === fiori_generator_shared_1.hostEnvironment.cli,
|
|
156
|
-
hideTableLayoutPrompts: generatorOptions.showLayoutPrompts === false // Defaults to show layout prompts
|
|
157
|
-
|
|
157
|
+
hideTableLayoutPrompts: generatorOptions.showLayoutPrompts === false, // Defaults to show layout prompts
|
|
158
|
+
...(templateType === types_1.FloorplanFE.FE_FPM && { displayPageBuildingBlockPrompt: true }) // If templateType is FPM, add displayPageBuildingBlockPrompt to promptOptions
|
|
159
|
+
};
|
|
160
|
+
const entityQuestions = (0, odata_service_inquirer_1.getEntityRelatedPrompts)(this.state.service.edmx, templateType, !!this.state.service.capService, promptOptions, this.state.service.annotations?.[0], FioriAppGenerator.logger, (0, fiori_generator_shared_1.getHostEnvironment)() !== fiori_generator_shared_1.hostEnvironment.cli);
|
|
158
161
|
const entityRelatedAnswers = await this.prompt(entityQuestions);
|
|
159
162
|
// Some state may have been assigned by adaptors, and then certain prompts hidden, so we must merge the answers
|
|
160
163
|
this.state.entityRelatedConfig = Object.assign(this.state.entityRelatedConfig ?? {}, entityRelatedAnswers);
|
|
@@ -65,6 +65,10 @@ function transformTemplateType(floorplan, entityRelatedConfig, viewName) {
|
|
|
65
65
|
};
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
|
+
// Add page title if addPageBuildingBlock is true
|
|
69
|
+
const pageBuildingBlockConfig = entityRelatedConfig?.addPageBuildingBlock
|
|
70
|
+
? { pageBuildingBlockTitle: entityRelatedConfig.pageBuildingBlockTitle }
|
|
71
|
+
: {};
|
|
68
72
|
const templateSettingsMap = {
|
|
69
73
|
[fiori_elements_writer_1.TemplateType.ListReportObjectPage]: {
|
|
70
74
|
entityConfig: _entityConfig,
|
|
@@ -96,6 +100,7 @@ function transformTemplateType(floorplan, entityRelatedConfig, viewName) {
|
|
|
96
100
|
},
|
|
97
101
|
[fiori_elements_writer_1.TemplateType.FlexibleProgrammingModel]: {
|
|
98
102
|
entityConfig: _entityConfig,
|
|
103
|
+
...pageBuildingBlockConfig,
|
|
99
104
|
pageName: types_1.FPM_DEFAULT_PAGE_NAME
|
|
100
105
|
}
|
|
101
106
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sap-ux/fiori-app-sub-generator",
|
|
3
3
|
"description": "A yeoman (sub) generator that can generate Fiori applications. Not for standalone use.",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.7.1",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/SAP/open-ux-tools.git",
|
|
@@ -34,12 +34,12 @@
|
|
|
34
34
|
"@sap-ux/btp-utils": "1.1.0",
|
|
35
35
|
"@sap-ux/cap-config-writer": "0.12.0",
|
|
36
36
|
"@sap-ux/feature-toggle": "0.3.0",
|
|
37
|
-
"@sap-ux/fiori-elements-writer": "2.
|
|
38
|
-
"@sap-ux/fiori-freestyle-writer": "2.4.
|
|
37
|
+
"@sap-ux/fiori-elements-writer": "2.6.1",
|
|
38
|
+
"@sap-ux/fiori-freestyle-writer": "2.4.37",
|
|
39
39
|
"@sap-ux/fiori-generator-shared": "0.13.9",
|
|
40
40
|
"@sap-ux/fiori-tools-settings": "0.2.0",
|
|
41
41
|
"@sap-ux/launch-config": "0.10.19",
|
|
42
|
-
"@sap-ux/odata-service-inquirer": "2.
|
|
42
|
+
"@sap-ux/odata-service-inquirer": "2.6.0",
|
|
43
43
|
"@sap-ux/odata-service-writer": "0.27.17",
|
|
44
44
|
"@sap-ux/project-access": "1.30.12",
|
|
45
45
|
"@sap-ux/store": "1.1.2",
|
|
@@ -62,8 +62,8 @@
|
|
|
62
62
|
"mock-spawn": "0.2.6",
|
|
63
63
|
"rimraf": "5.0.5",
|
|
64
64
|
"yeoman-test": "6.3.0",
|
|
65
|
-
"@sap-ux/deploy-config-sub-generator": "0.3.
|
|
66
|
-
"@sap-ux/flp-config-sub-generator": "0.3.
|
|
65
|
+
"@sap-ux/deploy-config-sub-generator": "0.3.60",
|
|
66
|
+
"@sap-ux/flp-config-sub-generator": "0.3.16",
|
|
67
67
|
"@sap-ux/inquirer-common": "0.7.35",
|
|
68
68
|
"@sap-ux/jest-file-matchers": "0.2.4",
|
|
69
69
|
"@sap-ux/logger": "0.7.0"
|