summaryrefslogtreecommitdiffstats
path: root/cds-ui/client/src/app/common/utility/zipfile-extraction.component.ts
diff options
context:
space:
mode:
authorDan Timoney <dtimoney@att.com>2019-09-12 13:56:46 +0000
committerGerrit Code Review <gerrit@onap.org>2019-09-12 13:56:46 +0000
commit6b8fbc694e204117efe3ae44c99ae08d64c11f9a (patch)
treed838d52c0325274015317ff8fe6b87168221cf72 /cds-ui/client/src/app/common/utility/zipfile-extraction.component.ts
parent8b24f42bcba5220f72b6977441867f774aca57df (diff)
parente23e6bf1b03fd7573c88dc77885c0ab9bcf1eb25 (diff)
Merge "Added mode for kt and create method"
Diffstat (limited to 'cds-ui/client/src/app/common/utility/zipfile-extraction.component.ts')
-rw-r--r--cds-ui/client/src/app/common/utility/zipfile-extraction.component.ts12
1 files changed, 11 insertions, 1 deletions
diff --git a/cds-ui/client/src/app/common/utility/zipfile-extraction.component.ts b/cds-ui/client/src/app/common/utility/zipfile-extraction.component.ts
index fcadee816..279405a6b 100644
--- a/cds-ui/client/src/app/common/utility/zipfile-extraction.component.ts
+++ b/cds-ui/client/src/app/common/utility/zipfile-extraction.component.ts
@@ -39,11 +39,21 @@ export class ZipfileExtractionComponent implements OnInit {
private entryDefinition: string;
validfile: boolean = false;
uploadedFileName: string;
-
+ filesData: any = [];
+
constructor(private loader: LoaderService) { }
ngOnInit() {
}
+
+ create() {
+ this.filesData.forEach((path) => {
+ let index = path.name.indexOf("/");
+ let name = path.name.slice(index + 1, path.name.length);
+ this.zipFile.file(name, path.data);
+ });
+ }
+
async buildFileViewData(zip) {
this.validfile = false;
this.paths = [];