summaryrefslogtreecommitdiffstats
path: root/cds-ui
diff options
context:
space:
mode:
authorEzhilarasi <ezhrajam@in.ibm.com>2019-07-02 19:44:37 +0530
committerEzhilarasi R <ezhrajam@in.ibm.com>2019-07-03 06:36:01 +0000
commitae3240b5de33f5dc462d9313afc894fce433b52c (patch)
tree991478bbd711d50bd2e184094962c2f48ad286d1 /cds-ui
parenta6fae85764a8dfbeba6000a060b8be0f21fb0466 (diff)
Search service for Controller Blueprint
Search service for controller blueprint creation and Search capability Change-Id: I20b7f60aa357af2785c6209003429d83b34c4342 Issue-ID: CCSDK-1269 Signed-off-by: Ezhilarasi <ezhrajam@in.ibm.com>
Diffstat (limited to 'cds-ui')
-rw-r--r--cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.service.spec.ts12
-rw-r--r--cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.service.ts16
2 files changed, 28 insertions, 0 deletions
diff --git a/cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.service.spec.ts b/cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.service.spec.ts
new file mode 100644
index 000000000..418b7e9ca
--- /dev/null
+++ b/cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.service.spec.ts
@@ -0,0 +1,12 @@
+import { TestBed } from '@angular/core/testing';
+
+import { SearchTemplateService } from './search-template.service';
+
+describe('SearchTemplateService', () => {
+ beforeEach(() => TestBed.configureTestingModule({}));
+
+ it('should be created', () => {
+ const service: SearchTemplateService = TestBed.get(SearchTemplateService);
+ expect(service).toBeTruthy();
+ });
+});
diff --git a/cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.service.ts b/cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.service.ts
new file mode 100644
index 000000000..fdb261d52
--- /dev/null
+++ b/cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.service.ts
@@ -0,0 +1,16 @@
+import { Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+import { Observable } from 'rxjs';
+import { ApiService } from '../../../../common/core/services/api.service';
+
+@Injectable({
+ providedIn: 'root'
+})
+export class SearchTemplateService {
+
+ constructor(private _http: HttpClient, private api: ApiService) { }
+
+ searchByTags(uri: string, searchText: String): Observable<any>{
+ return this.api.post(uri, searchText);
+ }
+}