add Enrich&Deploy function in designer
[ccsdk/cds.git] / cds-ui / designer-client / src / app / modules / feature-modules / packages / package-creation / package-creation.service.ts
index ed3db42..2625dc8 100644 (file)
@@ -63,6 +63,10 @@ export class PackageCreationService {
         return this.api.post(BlueprintURLs.enrich, body, {responseType: 'blob'});
     }
 
+    private enrichandpublish(body: any | null, options?: any): Observable<any> {
+        return this.api.post(BlueprintURLs.enrichandpublish, body, {responseType: 'blob'});
+    }
+
     private deployBluePrint(body: any | null, options?: any): Observable<any> {
         return this.api.post(BlueprintURLs.deploy, body, {responseType: 'text'});
     }
@@ -86,6 +90,11 @@ export class PackageCreationService {
         return this.enrichBlueprint(formData);
     }
 
+    enrichAndDeployPackage(blob) {
+        const formData = this.getFormData(blob);
+        return this.enrichandpublish(formData);
+    }
+
     deploy(blob) {
         const formData = this.getFormData(blob);
         return this.deployBluePrint(formData);