@sap-ux/fiori-app-sub-generator 0.3.0 → 0.4.0
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.
|
@@ -194,8 +194,9 @@ class FioriAppGenerator extends yeoman_generator_1.default {
|
|
|
194
194
|
(0, subgenHelpers_1.addDeployGen)({
|
|
195
195
|
service: this.state.service,
|
|
196
196
|
projectName: this.state.project.name,
|
|
197
|
+
promptSettings: generatorOptions.promptSettings,
|
|
197
198
|
targetFolder: this.state.project.targetFolder,
|
|
198
|
-
applicationType: 'FF' // Telemetry data
|
|
199
|
+
applicationType: this.state.floorplan === types_1.FloorplanFF.FF_SIMPLE ? 'FF' : 'FE' // Telemetry data
|
|
199
200
|
}, this.composeWith.bind(this), FioriAppGenerator.logger, this.appWizard);
|
|
200
201
|
}
|
|
201
202
|
if (this.state.project?.addFlpConfig) {
|
|
@@ -1,22 +1,24 @@
|
|
|
1
1
|
import type { AppWizard } from '@sap-devx/yeoman-ui-types';
|
|
2
2
|
import type { ILogWrapper } from '@sap-ux/fiori-generator-shared';
|
|
3
3
|
import type Generator from 'yeoman-generator';
|
|
4
|
-
import { type Service } from '../types';
|
|
4
|
+
import { type FioriAppGeneratorPromptSettings, type Service } from '../types';
|
|
5
5
|
/**
|
|
6
6
|
* Add the '@sap/fiori:fiori-deployment' generator as a subgenerator.
|
|
7
7
|
*
|
|
8
|
-
* @param
|
|
9
|
-
* @param
|
|
10
|
-
* @param
|
|
11
|
-
* @param
|
|
12
|
-
* @param
|
|
13
|
-
* @param
|
|
14
|
-
* @param
|
|
15
|
-
* @param
|
|
8
|
+
* @param deployGenOpts
|
|
9
|
+
* @param deployGenOpts.service - service object
|
|
10
|
+
* @param deployGenOpts.projectName - project name
|
|
11
|
+
* @param deployGenOpts.promptSettings - prompt settings for the deployment generator
|
|
12
|
+
* @param deployGenOpts.targetFolder - target folder for the deployment configuration
|
|
13
|
+
* @param deployGenOpts.applicationType - application type, used for telemetry (FF | FE)
|
|
14
|
+
* @param composeWith - the composeWith function from the Yeoman generator
|
|
15
|
+
* @param logger - logger instance
|
|
16
|
+
* @param appWizard - instance of the AppWizard
|
|
16
17
|
*/
|
|
17
|
-
export declare function addDeployGen({ service, projectName, targetFolder, applicationType }: {
|
|
18
|
+
export declare function addDeployGen({ service, projectName, promptSettings, targetFolder, applicationType }: {
|
|
18
19
|
service: Partial<Service>;
|
|
19
20
|
projectName: string;
|
|
21
|
+
promptSettings?: FioriAppGeneratorPromptSettings;
|
|
20
22
|
targetFolder: string;
|
|
21
23
|
applicationType: string;
|
|
22
24
|
}, composeWith: Generator['composeWith'], logger: ILogWrapper, appWizard?: AppWizard): void;
|
|
@@ -8,16 +8,17 @@ const utils_1 = require("../utils");
|
|
|
8
8
|
/**
|
|
9
9
|
* Add the '@sap/fiori:fiori-deployment' generator as a subgenerator.
|
|
10
10
|
*
|
|
11
|
-
* @param
|
|
12
|
-
* @param
|
|
13
|
-
* @param
|
|
14
|
-
* @param
|
|
15
|
-
* @param
|
|
16
|
-
* @param
|
|
17
|
-
* @param
|
|
18
|
-
* @param
|
|
11
|
+
* @param deployGenOpts
|
|
12
|
+
* @param deployGenOpts.service - service object
|
|
13
|
+
* @param deployGenOpts.projectName - project name
|
|
14
|
+
* @param deployGenOpts.promptSettings - prompt settings for the deployment generator
|
|
15
|
+
* @param deployGenOpts.targetFolder - target folder for the deployment configuration
|
|
16
|
+
* @param deployGenOpts.applicationType - application type, used for telemetry (FF | FE)
|
|
17
|
+
* @param composeWith - the composeWith function from the Yeoman generator
|
|
18
|
+
* @param logger - logger instance
|
|
19
|
+
* @param appWizard - instance of the AppWizard
|
|
19
20
|
*/
|
|
20
|
-
function addDeployGen({ service, projectName, targetFolder, applicationType }, composeWith, logger, appWizard) {
|
|
21
|
+
function addDeployGen({ service, projectName, promptSettings, targetFolder, applicationType }, composeWith, logger, appWizard) {
|
|
21
22
|
composeWith('@sap/fiori:deploy-config', {
|
|
22
23
|
launchDeployConfigAsSubGenerator: true,
|
|
23
24
|
appGenServiceHost: service.host,
|
|
@@ -30,7 +31,8 @@ function addDeployGen({ service, projectName, targetFolder, applicationType }, c
|
|
|
30
31
|
projectPath: targetFolder,
|
|
31
32
|
appWizard: appWizard,
|
|
32
33
|
telemetryData: { appType: applicationType },
|
|
33
|
-
logWrapper: logger
|
|
34
|
+
logWrapper: logger,
|
|
35
|
+
subGenPromptOptions: promptSettings?.['@sap-ux/deploy-config-sub-generator']
|
|
34
36
|
});
|
|
35
37
|
}
|
|
36
38
|
/**
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { DatasourceType, OdataServicePromptOptions, OdataVersion, promptNames } from '@sap-ux/odata-service-inquirer';
|
|
2
2
|
import type { UI5ApplicationPromptOptions } from '@sap-ux/ui5-application-inquirer';
|
|
3
|
+
import type { AbapDeployConfigPromptOptions } from '@sap-ux/abap-deploy-config-inquirer';
|
|
4
|
+
import type { CfDeployConfigPromptOptions } from '@sap-ux/cf-deploy-config-inquirer';
|
|
3
5
|
/**
|
|
4
6
|
* package.json script entries (commands and tasks)
|
|
5
7
|
*/
|
|
@@ -14,7 +16,9 @@ export type WorkspaceFolder = {
|
|
|
14
16
|
folderName: string;
|
|
15
17
|
path: string;
|
|
16
18
|
};
|
|
17
|
-
export type FioriAppGeneratorPromptSettings = UI5ApplicationPromptOptions & Pick<OdataServicePromptOptions, promptNames.systemSelection
|
|
19
|
+
export type FioriAppGeneratorPromptSettings = UI5ApplicationPromptOptions & Pick<OdataServicePromptOptions, promptNames.systemSelection | promptNames.serviceSelection> & {
|
|
20
|
+
'@sap-ux/deploy-config-sub-generator'?: AbapDeployConfigPromptOptions | CfDeployConfigPromptOptions;
|
|
21
|
+
};
|
|
18
22
|
/**
|
|
19
23
|
* Custom environment type until yeoman-environment provides one
|
|
20
24
|
*/
|
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.4.0",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/SAP/open-ux-tools.git",
|
|
@@ -62,6 +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/abap-deploy-config-inquirer": "1.4.5",
|
|
66
|
+
"@sap-ux/cf-deploy-config-inquirer": "0.3.3",
|
|
65
67
|
"@sap-ux/flp-config-sub-generator": "0.2.9",
|
|
66
68
|
"@sap-ux/inquirer-common": "0.7.3",
|
|
67
69
|
"@sap-ux/jest-file-matchers": "0.2.2",
|