Code Review
/
portal
/
ric-dashboard.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Add AC controller with get/put policy methods
[portal/ric-dashboard.git]
/
webapp-frontend
/
src
/
app
/
services
/
catalog
/
catalog.service.ts
diff --git
a/webapp-frontend/src/app/services/catalog/catalog.service.ts
b/webapp-frontend/src/app/services/catalog/catalog.service.ts
index
a5b2f9a
..
586df92
100644
(file)
--- a/
webapp-frontend/src/app/services/catalog/catalog.service.ts
+++ b/
webapp-frontend/src/app/services/catalog/catalog.service.ts
@@
-20,24
+20,24
@@
import { Injectable } from '@angular/core';
import { HttpClient } from '@angular/common/http';
import { Observable } from 'rxjs';
import { Injectable } from '@angular/core';
import { HttpClient } from '@angular/common/http';
import { Observable } from 'rxjs';
+import { XMXappInfo } from '../../interfaces/xapp-mgr.types';
@Injectable()
export class CatalogService {
@Injectable()
export class CatalogService {
-
- constructor(private http: HttpClient) {
+
+ constructor(private httpClient: HttpClient) {
+ // injects to variable httpClient
}
getAll() {
}
getAll() {
- return this.http.get('api/xappmgr/xapps');
+ return this.httpClient.get('api/xappmgr/xapps');
+ }
+
+ deployXapp(name) {
+ let xappInfo: XMXappInfo = {
+ xAppName: name
+ };
+ return this.httpClient.post('api/xappmgr/xapps', xappInfo, { observe: 'response' });
}
}
- deployXapp(name) {
- console.log(name);
- return this.http.post('api/xappmgr/xapps',
- {
- "xAppName": "string",
- "xappName": name
- });
- }
-
}
}