aboutsummaryrefslogtreecommitdiffstats
path: root/cds-ui/client/src/app
diff options
context:
space:
mode:
authorArundathi Patil <arundpil@in.ibm.com>2019-03-25 12:39:02 +0530
committerIBM602-PC0F1E3C\Arundathi <arundpil@in.ibm.com>2019-03-25 12:39:09 +0530
commit6c0366ef2bc92542f6bfce808476bd219dd06538 (patch)
treeccdfb08fa40e58af72dc26c4a66898663166a9d7 /cds-ui/client/src/app
parentffb6bdfd6de2afa23d95d0884c9db4059982deed (diff)
search-template change
Removed the use of the shift array method which was removing the base folder entry from tree. Issue-ID: CCSDK-1171 Change-Id: Ic07a9fb89f9daba8d773d1d592c49566b28ac8f9 Signed-off-by: Arundathi Patil <arundpil@in.ibm.com>
Diffstat (limited to 'cds-ui/client/src/app')
-rw-r--r--cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.component.ts6
1 files changed, 4 insertions, 2 deletions
diff --git a/cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.component.ts b/cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.component.ts
index 777faee68..36876233d 100644
--- a/cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.component.ts
+++ b/cds-ui/client/src/app/feature-modules/blueprint/select-template/search-template/search-template.component.ts
@@ -60,6 +60,7 @@ export class SearchTemplateComponent implements OnInit {
}
fileChanged(e: any) {
+ this.paths = [];
this.file = e.target.files[0];
this.zipFile.files = {};
this.zipFile.loadAsync(this.file)
@@ -119,7 +120,7 @@ export class SearchTemplateComponent implements OnInit {
paths.forEach((path) => {
const pathParts = path.name.split('/');
- pathParts.shift();
+ // pathParts.shift();
let currentLevel = tree;
pathParts.forEach((part) => {
@@ -131,7 +132,8 @@ export class SearchTemplateComponent implements OnInit {
const newPart = {
name: part,
children: [],
- data: path.data
+ data: path.data,
+ path : path.name
};
if(part.trim() == this.blueprintName.trim()) {
this.activationBlueprint = path.data;